/* ==============================
   14Digital — Global Design System (Light Theme)
   ============================== */

@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&display=swap');

/* ── Design Tokens ── */
:root {
  --primary: #E63946;
  --primary-light: #FF2D55;
  --primary-gradient: linear-gradient(135deg, #E63946 0%, #FF2D55 100%);
  --primary-glow: 0 0 30px rgba(230, 57, 70, 0.25);

  --bg-white: #FFFFFF;
  --bg-light: #F7F7F9;
  --bg-surface: #EEEEF2;
  --bg-card: rgba(0, 0, 0, 0.02);
  --bg-card-hover: rgba(0, 0, 0, 0.04);
  --bg-glass: rgba(255, 255, 255, 0.88);

  --text-primary: #1A1A2E;
  --text-secondary: #555566;
  --text-muted: #888899;
  --text-dark: #2D2D2D;
  --white: #FFFFFF;
  --border-color: rgba(0, 0, 0, 0.08);

  --font-heading: 'Arial', 'Helvetica Neue', Helvetica, sans-serif;
  --font-body: 'Roboto', sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 6rem;
  --space-2xl: 8rem;

  --max-width: 1200px;
  --nav-height: 72px;

  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ── Reset & Base ── */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--bg-white);
  overflow-x: hidden;
}

::selection {
  background: var(--primary);
  color: var(--white);
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-light); }
::-webkit-scrollbar-thumb { background: var(--bg-surface); border-radius: var(--radius-full); }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h1 { font-size: clamp(2.2rem, 5vw, 4rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.6rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); }

p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 680px;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

ul { list-style: none; }

img {
  max-width: 100%;
  display: block;
}

/* ── Utility ── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.section { padding: var(--space-xl) 0; }

.accent-line {
  width: 60px;
  height: 4px;
  background: var(--primary-gradient);
  border-radius: var(--radius-full);
  margin-bottom: var(--space-sm);
}

/* ── Responsive helper ── */
@media (max-width: 768px) {
  .container { padding: 0 var(--space-sm); }
  .section { padding: var(--space-lg) 0; }
}

/* ═══════════════════════════════════
   NAVBAR
   ═══════════════════════════════════ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
  display: flex;
  align-items: center;
}

.nav-container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.nav-logo img {
  height: 34px;
  width: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link {
  padding: 0.5rem 0.75rem;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--text-primary);
  background: var(--bg-card-hover);
}

.nav-link.active {
  color: var(--primary);
  background: rgba(230, 57, 70, 0.06);
}

/* Dropdown */
.dropdown-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
}

.dropdown-arrow {
  font-size: 0.7rem;
  margin-left: 0.2rem;
  opacity: 0.5;
  transition: transform var(--transition-fast);
}

.dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  padding: 0.5rem;
  background: var(--bg-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all var(--transition-fast);
  z-index: 100;
}

.dropdown-wrapper:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-dropdown {
  display: none;
}

.dropdown-link {
  display: block;
  padding: 0.6rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.dropdown-link:hover,
.dropdown-link.active {
  color: var(--primary);
  background: rgba(230, 57, 70, 0.06);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
}

.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: var(--radius-full);
  transition: all var(--transition-normal);
  display: block;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
  z-index: 998;
  opacity: 0;
  transition: opacity var(--transition-normal);
  pointer-events: none;
}

.nav-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 900px) {
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    height: 100vh;
    width: 280px;
    background: var(--bg-white);
    flex-direction: column;
    align-items: flex-start;
    padding: calc(var(--nav-height) + var(--space-md)) var(--space-md);
    gap: 0;
    transition: right var(--transition-normal);
    z-index: 999;
    box-shadow: -4px 0 30px rgba(0, 0, 0, 0.1);
    overflow-y: auto;
  }

  .nav-links.open { right: 0; }
  .nav-link { width: 100%; }
  .hamburger { display: flex; }
  .dropdown { display: none; }

  .mobile-dropdown {
    display: flex;
    flex-direction: column;
    width: 100%;
  }

  .mobile-sub-link {
    padding-left: 1.5rem;
    font-size: 0.82rem;
  }
}

/* ═══════════════════════════════════
   FOOTER
   ═══════════════════════════════════ */
.footer {
  padding: var(--space-xl) var(--space-md) var(--space-lg);
  background: var(--bg-light);
  border-top: 1px solid var(--border-color);
}

.footer-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-lg);
}

.footer-brand p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  max-width: 300px;
}

.footer-col-title {
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.footer-link {
  display: block;
  font-size: 0.88rem;
  color: var(--text-secondary);
  padding: 0.3rem 0;
  transition: color var(--transition-fast);
}

.footer-link:hover { color: var(--primary); }

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.footer-divider {
  max-width: var(--max-width);
  margin: var(--space-lg) auto var(--space-md);
  border: none;
  border-top: 1px solid var(--border-color);
}

.footer-bottom {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.footer-copyright {
  font-size: 0.8rem;
  color: var(--text-muted);
  max-width: none;
}

.footer-hashtags {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
  max-width: none;
}

@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--space-md); }
  .footer-bottom { flex-direction: column; align-items: center; text-align: center; }
}

@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════
   BUTTON
   ═══════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

.btn-primary {
  background: var(--primary-gradient);
  color: var(--white);
  box-shadow: 0 4px 15px rgba(230, 57, 70, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--primary-glow);
  color: var(--white);
}

.btn-outline {
  background: transparent;
  color: var(--primary-light);
  border: 2px solid var(--primary);
}

.btn-outline:hover {
  background: var(--primary-gradient);
  color: var(--white);
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: var(--primary-glow);
}

/* ═══════════════════════════════════
   ANIMATED SECTION
   ═══════════════════════════════════ */
.animated-section {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animated-section.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ═══════════════════════════════════
   HASHTAG BAR
   ═══════════════════════════════════ */
.hashtag-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.hashtag-tag {
  font-size: 0.88rem;
  color: var(--text-muted);
  padding: 0.25rem 0.5rem;
  transition: color var(--transition-fast);
}

.hashtag-tag:hover { color: var(--primary); }

/* ═══════════════════════════════════
   CHAT BUBBLE
   ═══════════════════════════════════ */
.chat-toggle {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: none;
  background: var(--primary-gradient);
  color: var(--white);
  font-size: 1.6rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 24px rgba(230, 57, 70, 0.35);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.chat-toggle:hover { transform: scale(1.08); box-shadow: 0 8px 32px rgba(230, 57, 70, 0.45); }

.chat-toggle.open {
  background: var(--text-primary);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.2);
  font-size: 1.2rem;
}

.chat-window {
  position: fixed;
  bottom: 100px;
  right: 24px;
  z-index: 9998;
  width: 380px;
  max-height: 520px;
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15), 0 4px 16px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.chat-window.open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.chat-header {
  padding: 1rem 1.25rem;
  background: var(--primary-gradient);
  color: var(--white);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.chat-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.chat-header-info h4 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--white);
  margin: 0;
  line-height: 1.3;
}

.chat-header-info p {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.8);
  margin: 0;
  max-width: none;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 200px;
  max-height: 320px;
  background: var(--bg-light);
}

.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--bg-surface); border-radius: var(--radius-full); }

.message-bubble {
  max-width: 85%;
  padding: 0.7rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  line-height: 1.5;
  word-wrap: break-word;
  animation: fadeInUp 0.2s ease;
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.message-user {
  align-self: flex-end;
  background: var(--primary);
  color: var(--white);
  border-bottom-right-radius: 4px;
  margin-left: auto;
}

.message-bot {
  align-self: flex-start;
  background: var(--bg-white);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-bottom-left-radius: 4px;
}

.typing-indicator {
  align-self: flex-start;
  display: flex;
  gap: 4px;
  padding: 0.7rem 1rem;
  background: var(--bg-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  border-bottom-left-radius: 4px;
}

.typing-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
  animation: typingBounce 1.4s ease-in-out infinite;
  display: inline-block;
}

.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-6px); opacity: 1; }
}

.chat-input-area {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--border-color);
  background: var(--bg-white);
  flex-shrink: 0;
}

.chat-input {
  flex: 1;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 0.6rem 1rem;
  font-size: 0.88rem;
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--bg-light);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.chat-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.1);
  background: var(--bg-white);
}

.chat-input::placeholder { color: var(--text-muted); }

.chat-send-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: var(--primary-gradient);
  color: var(--white);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
  flex-shrink: 0;
}

.chat-send-btn:hover { transform: scale(1.08); }
.chat-send-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

@media (max-width: 480px) {
  .chat-window { right: 12px; left: 12px; bottom: 90px; width: auto; max-height: 70vh; }
  .chat-toggle { bottom: 16px; right: 16px; width: 54px; height: 54px; font-size: 1.4rem; }
}

/* ═══════════════════════════════════
   PAGE HERO (shared inner-page style)
   ═══════════════════════════════════ */
.page-hero {
  min-height: 40vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-height) + var(--space-xl)) var(--space-md) var(--space-lg);
  background: radial-gradient(ellipse at 40% 50%, rgba(230, 57, 70, 0.04) 0%, transparent 50%), var(--bg-white);
}

.page-hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  width: 100%;
}

.page-hero-inner h1 {
  margin-bottom: var(--space-md);
  max-width: 750px;
}

.page-hero-inner p {
  max-width: 680px;
  font-size: 1.1rem;
  margin: 0;
}

/* ── Shared CTA section ── */
.cta-section {
  padding: var(--space-lg) 0;
  text-align: center;
}

.cta-content { text-align: center; }
.cta-content h2 { margin-bottom: var(--space-sm); }
.cta-content p { margin: 0 auto var(--space-md); font-size: 1.05rem; }

.cta-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  flex-wrap: wrap;
  margin-top: var(--space-md);
}
