    @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700&display=swap');

    * { margin: 0; padding: 0; box-sizing: border-box; }
    
    html, body { 
      height: 100%; 
      overflow: hidden; 
      font-family: 'Inter', sans-serif; 
      background-color: #1a202c; 
      color: #e2e8f0; 
    }
    
    /* Modal styles */
    .modal-overlay {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background-color: rgba(0, 0, 0, 0.8);
      display: flex;
      justify-content: center;
      align-items: center;
      z-index: 1000;
    }
    
    .modal-content {
      background-color: #2d3748;
      border-radius: 0.75rem;
      padding: 2rem;
      max-width: 800px;
      width: 90%;
      box-shadow: 0 20px 25px rgba(0, 0, 0, 0.3);
      border: 1px solid #4a5568;
    }
    
    /* Khusus untuk modal tentang - memastikan konten rata kiri */
    #about-modal .modal-content {
      text-align: left;
    }
    
    #about-modal .modal-content * {
      text-align: left;
    }
    
    .modal-title {
      font-size: 1.25rem;
      font-weight: 600;
      margin-bottom: 1rem;
      text-align: center;
      color: #ffffff;
    }
    
    .modal-description {
      text-align: center;
      margin-bottom: 1.5rem;
      color: #a0aec0;
      font-size: 0.875rem;
      line-height: 1.5;
    }
    
    .form-group {
      margin-bottom: 1rem;
    }
    
    .form-label {
      display: block;
      margin-bottom: 0.5rem;
      font-weight: 500;
      color: #e2e8f0;
    }
    
    .form-input {
      width: 100%;
      padding: 0.75rem;
      border: 1px solid #4a5568;
      border-radius: 0.5rem;
      background-color: #1a202c;
      color: #e2e8f0;
      font-size: 0.875rem;
    }
    
    .form-input:focus {
      outline: none;
      border-color: #4299e1;
      box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
    }
    
    .modal-buttons {
      display: flex;
      gap: 0.75rem;
      margin-top: 1.5rem;
    }
    
    .btn-primary {
      flex: 1;
      padding: 0.75rem 1rem;
      background-color: #4299e1;
      color: white;
      border: none;
      border-radius: 0.5rem;
      font-weight: 500;
      cursor: pointer;
      transition: background-color 0.2s;
    }
    
    .btn-primary:hover {
      background-color: #3182ce;
    }
    
    .btn-primary:disabled {
      background-color: #4a5568;
      cursor: not-allowed;
    }
    
    .hidden {
      display: none !important;
    }
    
    body { 
      display: flex; 
      justify-content: center; 
      align-items: center; 
      padding: 1rem; 
    }
    
    #chat-container { 
      background-color: #2d3748; 
      border-radius: 0.75rem; 
      box-shadow: 0 10px 15px rgba(0, 0, 0, 0.2); 
      width: 100%; 
      max-width: 800px; 
      height: calc(100vh - 2rem); 
      display: flex; 
      flex-direction: column; 
      overflow: hidden; 
    }
    
    .bg-gray-700 { 
      flex-shrink: 0; 
      background-color: #374151 !important;
      border-radius: 0.75rem 0.75rem 0 0;
    }
    
    #chat-content { 
      flex: 1; 
      display: flex; 
      flex-direction: column; 
      overflow: hidden; 
    }
    
    #messages { 
      flex: 1; 
      overflow-y: auto; 
      padding: 1rem; 
      display: flex; 
      flex-direction: column; 
      gap: 0.75rem; 
    }
    
    .message-bubble { 
      max-width: 80%; 
      padding: 0.75rem 1rem; 
      border-radius: 1.25rem; 
      margin-bottom: 0.5rem; 
      word-wrap: break-word; 
    }
    
    .user-message { 
      background-color: #4299e1; 
      align-self: flex-end; 
      margin-left: auto; 
      border-bottom-right-radius: 0.25rem; 
    }
    
    .ai-message { 
      background-color: #4a5568; 
      align-self: flex-start; 
      margin-right: auto; 
      border-bottom-left-radius: 0.25rem; 
    }
    
    .loading-spinner { 
      border: 4px solid rgba(255, 255, 255, 0.3); 
      border-top: 4px solid #fff; 
      border-radius: 50%; 
      width: 1.5rem; 
      height: 1.5rem; 
      animation: spin 1s linear infinite; 
      margin-left: 0.5rem; 
    }
    
    .ai-response { 
      background-color: #2d3748; 
      border-left: 4px solid #4299e1; 
      padding: 0.5rem; 
      margin: 0.5rem 0; 
      border-radius: 0.25rem; 
    }
    
    .disclaimer { 
      color: #fbbf24; 
      font-style: italic; 
      font-size: 0.875rem;
      margin-top: 0.75rem;
      padding: 0.5rem;
      background-color: rgba(251, 191, 36, 0.1);
      border-radius: 0.25rem;
      border-left: 3px solid #fbbf24;
    }
    
    /* Markdown styling */
    .ai-message strong {
      font-weight: 700;
      color: #ffffff;
    }
    
    .ai-message em {
      font-style: italic;
      color: #e2e8f0;
    }
    
    .ai-message code {
      background-color: #4a5568;
      color: #f7fafc;
      padding: 0.125rem 0.25rem;
      border-radius: 0.25rem;
      font-family: 'Courier New', monospace;
      font-size: 0.875rem;
    }
    
    .ai-message ul {
      margin: 0.5rem 0;
      padding-left: 1.5rem;
    }
    
    .ai-message li {
      margin: 0.25rem 0;
      line-height: 1.5;
    }
    
    .ai-message h1, .ai-message h2, .ai-message h3 {
      margin: 1rem 0 0.5rem 0;
      color: #ffffff;
      font-weight: 600;
    }
    
    .ai-message h1 {
      font-size: 1.25rem;
    }
    
    .ai-message h2 {
      font-size: 1.125rem;
    }
    
    .ai-message h3 {
      font-size: 1rem;
    }
    
    @keyframes spin { 
      0% { transform: rotate(0deg); } 
      100% { transform: rotate(360deg); } 
    }
    
    /* Custom scrollbar untuk messages */
    #messages::-webkit-scrollbar {
      width: 6px;
    }
    
    #messages::-webkit-scrollbar-track {
      background: #4a5568;
      border-radius: 3px;
    }
    
    #messages::-webkit-scrollbar-thumb {
      background: #718096;
      border-radius: 3px;
    }
    
    #messages::-webkit-scrollbar-thumb:hover {
      background: #a0aec0;
    }
    
    /* Input area styling */
    .input-area {
      flex-shrink: 0;
      background-color: #374151;
      border-radius: 0 0 0.75rem 0.75rem;
    }
    
    /* Mobile responsive design */
    @media (max-width: 768px) {
      body {
        padding: 0;
        height: 100vh;
        height: 100dvh; /* Dynamic viewport height for mobile */
        height: calc(var(--vh, 1vh) * 100);
        overflow: hidden;
      }
      
      #chat-container {
        height: 100vh;
        height: 100dvh;
        height: calc(var(--vh, 1vh) * 100);
        max-width: none;
        border-radius: 0;
        box-shadow: none;
        position: relative;
      }
      
      .bg-gray-700 {
        border-radius: 0;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 100;
        background-color: #374151 !important;
        border-bottom: 1px solid #4a5568;
        height: 60px;
        display: flex;
        align-items: center;
        padding: 0 1rem;
      }
      
      #chat-content {
        margin-top: 60px; /* Height of header */
        margin-bottom: 80px; /* Height of input area */
        height: calc(100vh - 140px);
        height: calc(100dvh - 140px);
        height: calc(calc(var(--vh, 1vh) * 100) - 140px);
      }
      
      #messages {
        padding: 0.75rem;
        height: 100%;
        overflow-y: auto;
      }
      
      .input-area {
        border-radius: 0;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 100;
        padding: 0.75rem;
        background-color: #374151;
        border-top: 1px solid #4a5568;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
        height: 80px;
        display: flex;
        align-items: center;
      }
      
      /* Ensure input stays visible when keyboard opens */
      #user-input {
        font-size: 16px; /* Prevents zoom on iOS */
      }
      
      /* Handle keyboard on mobile */
      @media (max-height: 500px) {
        #chat-content {
          margin-bottom: 70px;
          height: calc(100vh - 130px);
          height: calc(100dvh - 130px);
          height: calc(calc(var(--vh, 1vh) * 100) - 130px);
        }
      }
    }
    
    /* iOS Safari specific fixes */
    @supports (-webkit-touch-callout: none) {
      body {
        height: -webkit-fill-available;
      }
      
      #chat-container {
        height: -webkit-fill-available;
      }
    }
