@font-face {
  font-family: 'GoogleSans';
  src: url('../assets/GoogleSans.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: block;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'GoogleSans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  background: #ffffff;
  color: #1a1f3a;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 0;
  opacity: 0;
  transition: opacity 0.5s ease-out;
}

body.loaded {
  opacity: 1;
}

.site-header {
  padding: 24px 32px;
  background: #ffffff;
}

.logo {
  height: 48px;
  width: auto;
  max-width: 200px;
  max-height: 48px;
  display: block;
  object-fit: contain;
}

.container {
  width: 100%;
  max-width: 900px;
  display: flex;
  flex-direction: column;
  gap: 48px;
  margin: 0 auto;
  padding: 40px 20px 80px;
  flex: 1;
}


.intro-text {
  text-align: center;
}

.intro-title {
  font-family: 'GoogleSans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  font-size: clamp(48px, 8vw, 96px);
  font-weight: 900;
  color: #0f172a;
  margin: 0 0 24px 0;
  letter-spacing: -3px;
  line-height: 0.95;
}

.intro-title .highlight-ai {
  color: #1a73e8;
  /* Google Blue */
}

.intro-title .highlight-faster {
  color: #34a853;
  /* Google Green */
}

.intro-description {
  font-size: 18px;
  color: #64748b;
  line-height: 1.6;
  max-width: 700px;
  margin: 0 auto;
  font-weight: 400;
}

.chat-section {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
}

.chat-description {
  text-align: center;
  font-size: 16px;
  color: #0f172a;
  margin-bottom: 24px;
  font-weight: 600;
  background: linear-gradient(135deg, #ea4335 0%, #1a73e8 50%, #34a853 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.chat-wrapper {
  width: 100%;
  background: #ffffff;
  border-radius: 32px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
}

.chat-messages {
  min-height: 300px;
  max-height: 400px;
  height: 400px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-bottom: 1px solid #e5e7eb;
  justify-content: flex-start;
}

.chat-messages::-webkit-scrollbar {
  width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: #dadce0;
  border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
  background: #bdc1c6;
}

.message {
  display: flex;
  animation: slideIn 0.2s ease-out;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.user-message {
  justify-content: flex-end;
}

.message-content {
  max-width: 75%;
  padding: 12px 16px;
  border-radius: 20px;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 400;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.user-message .message-content {
  background: #1a73e8;
  color: #ffffff;
  border-radius: 20px 20px 4px 20px;
  box-shadow: 0 1px 2px rgba(26, 115, 232, 0.2);
}

.ai-message .message-content {
  background: #f8f9fa;
  color: #202124;
  border-radius: 20px 20px 20px 4px;
  border: 1px solid #e8eaed;
}

.message-content p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 400;
  word-wrap: break-word;
}

.message-content.markdown {
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.message-content.markdown p {
  margin: 0 0 6px 0;
  line-height: 1.6;
}

.message-content.markdown p:last-child {
  margin-bottom: 0;
}

.message-content.markdown ul,
.message-content.markdown ol {
  margin: 6px 0;
  padding-left: 20px;
}

.message-content.markdown li {
  margin: 3px 0;
  line-height: 1.5;
}

.message-content.markdown code {
  background: rgba(0, 0, 0, 0.06);
  padding: 2px 5px;
  border-radius: 3px;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  color: #d63384;
}

.message-content.markdown pre {
  background: rgba(0, 0, 0, 0.04);
  padding: 10px;
  border-radius: 6px;
  overflow-x: auto;
  margin: 8px 0;
  border-left: 3px solid #1a73e8;
}

.message-content.markdown pre code {
  background: none;
  padding: 0;
  color: inherit;
}

.message-content.markdown strong {
  font-weight: 600;
  color: inherit;
}

.message-content.markdown em {
  font-style: italic;
}

.message-content.markdown a {
  color: #1a73e8;
  text-decoration: none;
  border-bottom: 1px solid rgba(26, 115, 232, 0.3);
}

.message-content.markdown a:hover {
  border-bottom-color: #1a73e8;
}

.message-content.markdown h1,
.message-content.markdown h2,
.message-content.markdown h3 {
  margin: 12px 0 6px 0;
  font-weight: 600;
  line-height: 1.3;
}

.message-content.markdown h1 {
  font-size: 18px;
}

.message-content.markdown h2 {
  font-size: 16px;
}

.message-content.markdown h3 {
  font-size: 15px;
}

.message-content.markdown blockquote {
  margin: 8px 0;
  padding-left: 12px;
  border-left: 3px solid #dadce0;
  color: #5f6368;
  font-style: italic;
}

.chat-input-container {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  background: #ffffff;
  border-radius: 32px;
}

.input-wrapper {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
}

.chat-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 16px;
  font-family: 'GoogleSans', sans-serif;
  font-weight: 400;
  color: #1a1f3a;
  padding: 8px 12px;
  width: 100%;
  position: relative;
  z-index: 1;
}

.placeholder-container {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #9aa0a6;
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  z-index: 0;
  font-size: 16px;
  font-weight: 400;
  opacity: 1;
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.placeholder-container.hidden {
  opacity: 0;
  transform: translateY(-50%) translateY(-5px);
}

.placeholder-container .business-name {
  font-weight: 500;
  transition: color 0.6s ease;
  /* Color is set inline via JavaScript to rotate through Google colors */
}

.icon-button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #5f6368;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  flex-shrink: 0;
}

.icon-button:hover:not(.disabled) {
  background: #f1f3f4;
}

.icon-button.disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}

.send-button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: #1a1f3a;
  color: #ffffff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
  position: relative;
}

.send-button:hover:not(:disabled) {
  background: #0f172a;
  transform: scale(1.05);
}

.send-button:active:not(:disabled) {
  transform: scale(0.95);
}

.send-button:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.send-button .spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.send-button .arrow-icon {
  display: block;
}

.send-button.loading .arrow-icon {
  display: none;
}

.send-button .spinner {
  display: none;
}

.send-button.loading .spinner {
  display: block;
}

.site-footer {
  margin-top: auto;
  padding: 48px 32px 40px;
  background: #f8f9fa;
  border-top: 1px solid #e8eaed;
}

.footer-content {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.footer-tagline {
  font-size: 14px;
  color: #5f6368;
  margin: 0 0 12px 0;
  font-weight: 400;
  line-height: 1.5;
}

.footer-copyright {
  font-size: 12px;
  color: #9aa0a6;
  margin: 0;
  font-weight: 400;
}

@media (max-width: 768px) {
  .container {
    gap: 32px;
  }

  .intro-title {
    font-size: clamp(40px, 10vw, 60px);
    letter-spacing: -2px;
  }

  .intro-description {
    font-size: 16px;
  }

  .chat-wrapper {
    border-radius: 24px;
  }

  .chat-input-container {
    padding: 8px;
    gap: 6px;
  }

  .icon-button {
    width: 36px;
    height: 36px;
  }

  .send-button {
    width: 36px;
    height: 36px;
  }

  .chat-input {
    font-size: 15px;
    padding: 6px 10px;
  }

  .placeholder-container {
    font-size: 15px;
    left: 10px;
  }

  .chat-description {
    font-size: 14px;
    margin-bottom: 16px;
  }

  .chat-messages {
    min-height: 250px;
    max-height: 300px;
    height: 300px;
    padding: 16px;
    gap: 10px;
  }

  .message-content {
    max-width: 85%;
    padding: 10px 14px;
    font-size: 13px;
    border-radius: 18px;
  }

  .user-message .message-content {
    border-radius: 18px 18px 4px 18px;
  }

  .ai-message .message-content {
    border-radius: 18px 18px 18px 4px;
  }

  .site-header {
    padding: 20px 24px;
  }

  .logo {
    height: 40px;
  }

  .container {
    padding: 40px 20px 60px;
  }

  .site-footer {
    padding: 40px 24px 32px;
  }

  .footer-tagline {
    font-size: 13px;
    margin-bottom: 10px;
  }

  .footer-copyright {
    font-size: 11px;
  }

}