    html, body {
      height: 100%;
      margin: 0;
      padding: 0;
      font-family: Arial, sans-serif;
      overflow: hidden;
    }

    /* Login Screen Styles */
    #login-screen {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      height: 100%;
      background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
      padding: 20px;
      box-sizing: border-box;
    }

    .login-container {
      background: white;
      border-radius: 20px;
      box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
      max-width: 450px;
      width: 100%;
      padding: 40px;
      text-align: center;
    }

    .login-container h1 {
      color: #333;
      margin-bottom: 10px;
      font-size: 28px;
    }

    .login-container .subtitle {
      color: #666;
      margin-bottom: 30px;
      font-size: 14px;
    }

    .google-btn {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 12px;
      background: white;
      border: 2px solid #ddd;
      border-radius: 8px;
      padding: 12px 24px;
      font-size: 16px;
      font-weight: 500;
      color: #333;
      cursor: pointer;
      transition: all 0.3s ease;
      width: 100%;
      margin-bottom: 20px;
    }

    .google-btn:hover {
      background: #f8f9fa;
      border-color: #4285f4;
      box-shadow: 0 2px 8px rgba(66, 133, 244, 0.2);
    }

    .google-btn:disabled {
      opacity: 0.6;
      cursor: not-allowed;
    }

    .google-icon {
      width: 24px;
      height: 24px;
    }

    .error-message {
      background: #fee;
      color: #c33;
      padding: 12px;
      border-radius: 8px;
      margin-top: 20px;
      display: none;
      font-size: 14px;
    }

    .error-message.active {
      display: block;
    }

    /* Chat Screen Styles */
    #chat {
      height: 100%;
      width: 100%;
      display: none;
      flex-direction: column;
      position: absolute;
      top: 0;
      left: 0;
    }

    .chat-header {
      padding: 10px 20px;
      background: white;
      box-shadow: 0 2px 5px rgba(0,0,0,0.1);
      z-index: 10;
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .chat-header h2 {
      margin: 0;
    }

    .user-info {
      display: flex;
      align-items: center;
      gap: 10px;
    }

    .user-photo {
      width: 32px;
      height: 32px;
      border-radius: 50%;
      object-fit: cover;
    }

    .sign-out-btn {
      background: #667eea;
      color: white;
      border: none;
      border-radius: 6px;
      padding: 8px 16px;
      font-size: 14px;
      cursor: pointer;
      transition: background 0.3s;
    }

    .sign-out-btn:hover {
      background: #5568d3;
    }

    #messages {
      flex: 1;
      overflow-y: auto;
      padding: 10px 20px;
      background-color: #f9f9f9;
      -webkit-overflow-scrolling: touch;
    }

    .message {
      margin: 8px 0;
      padding: 8px 12px;
      border-radius: 8px;
      background-color: white;
      box-shadow: 0 1px 2px rgba(0,0,0,0.1);
      max-width: 80%;
      position: relative;
    }

    .message.system {
      font-style: italic;
      color: #888;
      background-color: #f0f0f0;
    }

    .message .sender {
      font-weight: bold;
      margin-right: 5px;
    }

    .message .time {
      font-size: 0.8em;
      color: #888;
    }

    .message .content {
      word-break: break-word;
    }

    .message .content img {
      max-width: 100%;
      max-height: 300px;
      border-radius: 4px;
      margin-top: 8px;
    }

    .message .content a {
      color: #4a89dc;
      text-decoration: none;
    }

    .message .content a:hover {
      text-decoration: underline;
    }

    .delete-btn {
      position: absolute;
      top: 8px;
      right: 8px;
      background-color: #ff5555;
      color: white;
      border: none;
      border-radius: 4px;
      padding: 3px 6px;
      font-size: 0.8em;
      cursor: pointer;
      opacity: 0;
      transition: opacity 0.2s;
    }

    .message:hover .delete-btn {
      opacity: 1;
    }

    @media (hover: none) {
      .delete-btn {
        opacity: 1;
      }
    }

    #chat-form {
      padding: 12px 20px;
      background: white;
      box-shadow: 0 -2px 5px rgba(0,0,0,0.1);
      display: flex;
      gap: 10px;
    }

    #message-input {
      flex-grow: 1;
      padding: 10px;
      border: 1px solid #ccc;
      border-radius: 4px;
    }

    #send {
      padding: 10px 20px;
      border: none;
      border-radius: 4px;
      background-color: #4a89dc;
      color: white;
      cursor: pointer;
    }

    #send:hover {
      background-color: #3b7dd8;
    }

    @media (max-width: 480px) {
      #chat-form {
        padding: 10px;
      }

      #send {
        padding: 10px 15px;
      }
    }

    @supports (-webkit-touch-callout: none) {
      body, html {
        height: -webkit-fill-available;
      }

      #chat, #login-screen {
        height: -webkit-fill-available;
      }
    }