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

/* ==========================================
   CSS CUSTOM VARIABLES & DESIGN THEMES
   ========================================== */
:root {
  /* Light Mode Color Scheme */
  --bg-primary: #f8fafc;
  --bg-secondary: #f1f5f9;
  --surface: #ffffff;
  --surface-glass: rgba(255, 255, 255, 0.75);
  --border: #e2e8f0;
  --border-focus: #a5b4fc;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --primary-glow: rgba(79, 70, 229, 0.15);
  --accent: #d946ef;
  --accent-glow: rgba(217, 70, 239, 0.15);
  --success: #10b981;
  --success-glow: rgba(16, 185, 129, 0.15);
  --danger: #ef4444;
  
  /* Layout & Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 20px rgba(79, 70, 229, 0.2);
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
  --font-heading: 'Outfit', sans-serif;
  
  --max-width: 1200px;
  --nav-height: 80px;
}

[data-theme="dark"] {
  /* Dark Mode Color Scheme */
  --bg-primary: #090d16;
  --bg-secondary: #0f172a;
  --surface: #1e293b;
  --surface-glass: rgba(15, 23, 42, 0.75);
  --border: #334155;
  --border-focus: #6366f1;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --primary: #818cf8;
  --primary-hover: #6366f1;
  --primary-glow: rgba(129, 140, 248, 0.25);
  --accent: #f472b6;
  --accent-glow: rgba(244, 114, 182, 0.25);
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5), 0 2px 4px -2px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -4px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(129, 140, 248, 0.25);
}

/* ==========================================
   RESET & SYSTEM STYLES
   ========================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  height: 100%;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

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

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
}

button {
  cursor: pointer;
}

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.25;
}

/* ==========================================
   HEADER & NAVIGATION BAR
   ========================================== */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  z-index: 1000;
  background: var(--surface-glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

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

.logo-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.5rem;
  box-shadow: var(--shadow-glow);
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-link {
  font-weight: 500;
  color: var(--text-muted);
  position: relative;
  padding: 0.5rem 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: var(--radius-full);
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-main);
}

.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Light/Dark Toggle */
.theme-toggle-btn {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
  color: var(--text-muted);
}

.theme-toggle-btn:hover {
  border-color: var(--border-focus);
  color: var(--text-main);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.theme-toggle-btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: var(--transition);
}

[data-theme="dark"] .sun-icon {
  display: block;
}
[data-theme="dark"] .moon-icon {
  display: none;
}
.sun-icon {
  display: none;
}
.moon-icon {
  display: block;
}

/* Mobile Hamburger Menu */
.menu-toggle-btn {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
  color: var(--text-muted);
}

.menu-toggle-btn:hover {
  color: var(--text-main);
  border-color: var(--border-focus);
}

.menu-toggle-btn svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ==========================================
   MAIN MAIN WRAPPER
   ========================================== */
main {
  flex: 1 0 auto;
  margin-top: var(--nav-height);
  width: 100%;
}

/* ==========================================
   HERO SECTION
   ========================================== */
.hero-section {
  position: relative;
  padding: 6rem 2rem 4rem 2rem;
  text-align: center;
  background: radial-gradient(circle at 10% 20%, var(--primary-glow) 0%, transparent 40%),
              radial-gradient(circle at 90% 80%, var(--accent-glow) 0%, transparent 40%);
  overflow: hidden;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  background: var(--surface-glass);
  border: 1px solid var(--border);
  color: var(--primary);
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-sm);
  animation: fadeInDown 0.6s ease;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
  line-height: 1.15;
  animation: fadeInUp 0.6s ease;
}

.hero-title span {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 650px;
  margin: 0 auto 2.5rem auto;
  animation: fadeInUp 0.8s ease;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 2rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  font-weight: 600;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-glow);
  transition: var(--transition);
  animation: fadeInUp 1s ease;
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(79, 70, 229, 0.4);
}

.hero-cta svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2.5;
  fill: none;
}

/* ==========================================
   TOOL SECTION (CORE APPLICATION)
   ========================================== */
.tool-section {
  padding: 2rem;
  max-width: var(--max-width);
  margin: 0 auto 6rem auto;
}

.tool-card {
  background: var(--surface-glass);
  border: 1px solid var(--border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: 2.5rem;
  display: grid;
  grid-template-columns: 350px 1fr;
  gap: 2.5rem;
}

@media (max-width: 968px) {
  .tool-card {
    grid-template-columns: 1fr;
    padding: 1.5rem;
  }
}

/* Tool Settings Container */
.tool-settings {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  border-right: 1px solid var(--border);
  padding-right: 2.5rem;
}

@media (max-width: 968px) {
  .tool-settings {
    border-right: none;
    padding-right: 0;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border);
  }
}

.setting-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.setting-label {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.label-hint {
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--primary);
}

/* Segmented Options Control (Type Selection) */
.segmented-control {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 0.25rem;
  border: 1px solid var(--border);
}

.segmented-option {
  position: relative;
}

.segmented-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.segmented-label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.625rem 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: calc(var(--radius-md) - 2px);
  cursor: pointer;
  transition: var(--transition-fast);
  text-align: center;
}

.segmented-option input[type="radio"]:checked + .segmented-label {
  background: var(--surface);
  color: var(--primary);
  box-shadow: var(--shadow-sm);
}

/* Control Inputs */
.number-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.number-btn {
  width: 44px;
  height: 44px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}

.number-btn:first-of-type {
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  border-right: none;
}

.number-btn:last-of-type {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  border-left: none;
}

.number-btn:hover {
  background: var(--border);
  color: var(--text-main);
}

.number-btn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 2.5;
}

.number-input {
  flex: 1;
  height: 44px;
  border: 1px solid var(--border);
  background: var(--surface);
  text-align: center;
  font-weight: 600;
  font-size: 1.05rem;
}

.number-input:focus {
  border-color: var(--border-focus);
}

.range-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--bg-secondary);
  outline: none;
  margin: 0.75rem 0;
}

.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: var(--radius-full);
  background: var(--primary);
  border: 2px solid var(--surface);
  box-shadow: var(--shadow-md);
  cursor: pointer;
  transition: var(--transition-fast);
}

.range-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

/* Custom Checkbox styles */
.checkbox-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-muted);
  transition: var(--transition-fast);
}

.checkbox-item:hover {
  color: var(--text-main);
}

.checkbox-item input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.checkbox-custom {
  position: relative;
  height: 22px;
  width: 22px;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: var(--transition-fast);
}

.checkbox-item input[type="checkbox"]:checked ~ .checkbox-custom {
  background-color: var(--primary);
  border-color: var(--primary);
}

.checkbox-custom::after {
  content: "";
  position: absolute;
  display: none;
  left: 7px;
  top: 3px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg);
}

.checkbox-item input[type="checkbox"]:checked ~ .checkbox-custom::after {
  display: block;
}

/* Generate Button */
.generate-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 1.05rem;
  box-shadow: var(--shadow-glow);
  transition: var(--transition);
  margin-top: 1rem;
}

.generate-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.generate-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2.5;
  fill: none;
  animation: pulse 2s infinite;
}

/* Tool Display Container */
.tool-display {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 480px;
}

.display-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.stats-container {
  display: flex;
  gap: 1.25rem;
}

.stat-chip {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--text-muted);
}

.stat-chip span {
  color: var(--primary);
  margin-left: 0.25rem;
}

/* Output Text Box */
.output-wrapper {
  position: relative;
  flex: 1;
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.output-textarea {
  flex: 1;
  width: 100%;
  padding: 1.5rem;
  resize: none;
  background: transparent;
  color: var(--text-main);
  font-size: 1.05rem;
  line-height: 1.75;
  overflow-y: auto;
  border: none;
  outline: none;
}

/* Monospace output for HTML code block option */
.output-textarea.code-mode {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.95rem;
  color: var(--primary);
}

/* Action Toolbar */
.action-toolbar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 1rem;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-muted);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}

.action-btn:hover {
  background: var(--bg-secondary);
  border-color: var(--border-focus);
  color: var(--text-main);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.action-btn.copy-btn {
  background: var(--surface);
  border-color: var(--border);
}

.action-btn.copy-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.action-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2.25;
  fill: none;
}

/* ==========================================
   FAQ SECTION (ACCORDIONS)
   ========================================== */
.faq-section {
  padding: 4rem 2rem;
  background: var(--bg-secondary);
}

.section-container {
  max-width: 800px;
  margin: 0 auto;
}

.section-title {
  text-align: center;
  font-size: 2.25rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  max-width: 500px;
  margin: 0 auto 3rem auto;
  font-size: 1.05rem;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.faq-item:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border-focus);
}

.faq-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  text-align: left;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text-main);
}

.faq-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--bg-secondary);
  color: var(--text-muted);
  transition: var(--transition);
}

.faq-icon svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 2.5;
  fill: none;
}

.faq-item.active .faq-icon {
  background: var(--primary-glow);
  color: var(--primary);
  transform: rotate(180deg);
}

.faq-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: var(--bg-primary);
}

.faq-content-inner {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.6;
}

/* ==========================================
   ABOUT & INFORMATION PAGES CONTENT
   ========================================== */
.content-page-hero {
  padding: 5rem 2rem 3rem 2rem;
  text-align: center;
  background: radial-gradient(circle at 50% 100%, var(--primary-glow) 0%, transparent 60%);
  border-bottom: 1px solid var(--border);
}

.info-section {
  padding: 4rem 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.rich-content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-main);
}

.rich-content p {
  margin-bottom: 1.5rem;
  color: var(--text-muted);
}

.rich-content h2 {
  font-size: 1.75rem;
  margin: 2.5rem 0 1rem 0;
  color: var(--text-main);
  position: relative;
}

.rich-content h2::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--primary);
  margin-top: 0.5rem;
  border-radius: var(--radius-full);
}

.rich-content h3 {
  font-size: 1.35rem;
  margin: 2rem 0 0.75rem 0;
}

.rich-content ul {
  list-style: disc;
  margin: 1.25rem 0 1.25rem 2rem;
  color: var(--text-muted);
}

.rich-content li {
  margin-bottom: 0.5rem;
}

/* ==========================================
   CONTACT PAGE SPECIFIC STYLES
   ========================================== */
.contact-container {
  display: grid;
  grid-template-columns: 1.2fr 1.8fr;
  gap: 3rem;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2.5rem;
}

@media (max-width: 768px) {
  .contact-container {
    grid-template-columns: 1fr;
    padding: 1.5rem;
  }
}

.contact-info-panel {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 3rem 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  box-shadow: var(--shadow-lg);
}

.contact-info-heading h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.contact-info-heading p {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.contact-detail-item {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.detail-icon {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.detail-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.detail-text strong {
  display: block;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.detail-text span {
  font-weight: 500;
}

/* Contact Form CSS */
.contact-form-panel {
  background: var(--surface-glass);
  border: 1px solid var(--border);
  backdrop-filter: blur(16px);
  border-radius: var(--radius-lg);
  padding: 3rem;
  box-shadow: var(--shadow-xl);
}

@media (max-width: 768px) {
  .contact-form-panel {
    padding: 1.75rem;
  }
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 580px) {
  .form-group-row {
    grid-template-columns: 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  height: 48px;
  padding: 0 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  color: var(--text-main);
  font-weight: 500;
}

textarea.form-control {
  height: 150px;
  padding: 1rem;
  resize: vertical;
}

.form-control:focus {
  border-color: var(--border-focus);
  background: var(--surface);
  box-shadow: 0 0 0 4px var(--primary-glow);
}

.form-error-msg {
  font-size: 0.8rem;
  color: var(--danger);
  font-weight: 600;
  display: none;
}

.form-control.invalid {
  border-color: var(--danger);
}

.form-control.invalid ~ .form-error-msg {
  display: block;
  animation: shake 0.3s ease-in-out;
}

.submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.9rem 2rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  border-radius: var(--radius-md);
  font-weight: 600;
  box-shadow: var(--shadow-glow);
  transition: var(--transition);
  margin-top: 0.5rem;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.submit-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2.25;
  fill: none;
}

/* ==========================================
   TOAST / DYNAMIC POPUPS
   ========================================== */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (max-width: 580px) {
  .toast-container {
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
  }
}

.toast {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  animation: slideInRight 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  min-width: 280px;
}

.toast.toast-success {
  border-left: 4px solid var(--success);
}

.toast.toast-error {
  border-left: 4px solid var(--danger);
}

.toast-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast-icon.success-icon {
  color: var(--success);
}

.toast-icon.error-icon {
  color: var(--danger);
}

.toast-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2.5;
  fill: none;
}

.toast-message {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-main);
}

.toast.toast-exit {
  animation: slideOutRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* ==========================================
   FOOTER SECTION
   ========================================== */
footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 4rem 2rem 2rem 2rem;
  width: 100%;
}

.footer-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

@media (max-width: 768px) {
  .footer-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.footer-logo-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.2rem;
}

.footer-logo-text {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.95rem;
  max-width: 380px;
}

.footer-column {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.footer-column h3 {
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-main);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-link {
  font-size: 0.95rem;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
}

.footer-link:hover {
  color: var(--primary);
  transform: translateX(3px);
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: var(--transition-fast);
}

.social-btn:hover {
  border-color: var(--border-focus);
  color: var(--primary);
  transform: translateY(-2px);
}

.social-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.footer-bottom {
  max-width: var(--max-width);
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.copyright {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-bottom-links {
  display: flex;
  gap: 1.5rem;
}

.footer-bottom-link {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-bottom-link:hover {
  color: var(--text-main);
}

@media (max-width: 580px) {
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
  .footer-bottom-links {
    justify-content: center;
  }
}

/* ==========================================
   ANIMATIONS & KEYFRAMES
   ========================================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.95;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(100%) translateY(0);
  }
  to {
    opacity: 1;
    transform: translateX(0) translateY(0);
  }
}

@keyframes slideOutRight {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}
