/* ============================================================
   public-site/css/style.css
   Khan Creative Studio — main styles
   ============================================================ */

/* ---------- CSS Variables ---------- */
:root {
  --color-primary: #4C1D95;
  --color-primary-dark: #2E1065;
  --color-primary-mid: #5B21B6;
  --color-accent: #7FE5D3;
  --color-accent-dark: #5BC4B1;
  --bg: #FFFFFF;
  --bg-soft: #F9FAFB;
  --bg-lavender: #EDE9FE;
  --text: #111827;
  --text-muted: #4B5563;
  --border: #E5E7EB;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, .06);
  --shadow-md: 0 6px 24px rgba(76, 29, 149, .08);
  --shadow-lg: 0 18px 48px rgba(76, 29, 149, .14);
  --container: 1180px;
  --font-head: 'Poppins', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  opacity: 0;
  transition: opacity .25s ease;
}

body.kcs-ready {
  opacity: 1;
}

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

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color .2s;
}

a:hover {
  color: var(--color-primary-mid);
}

button {
  font-family: inherit;
  cursor: pointer;
}

h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text);
  margin: 0 0 .5em;
}

h1 {
  font-size: clamp(2rem, 4.5vw, 3.25rem);
}

h2 {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
}

h3 {
  font-size: clamp(1.15rem, 2vw, 1.4rem);
}

p {
  margin: 0 0 1em;
  color: var(--text-muted);
}

.container {
  width: min(100% - 2rem, var(--container));
  margin-inline: auto;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .85rem 1.6rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  border: 2px solid transparent;
  min-height: 44px;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}

.btn:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-primary-dark);
}

.btn-primary:hover {
  background: var(--color-accent-dark);
  color: var(--color-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(127, 229, 211, .35);
}

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

.btn-outline:hover {
  background: var(--color-primary);
  color: #fff;
  transform: translateY(-2px);
}

.btn-ghost {
  background: #fff;
  color: var(--color-primary);
  box-shadow: var(--shadow-sm);
}

.btn-ghost:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

/* ---------- Navbar ---------- */
.kcs-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: box-shadow .2s, border-color .2s;
}

.kcs-header.scrolled {
  box-shadow: 0 4px 20px rgba(76, 29, 149, .08);
  border-bottom-color: var(--border);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: .65rem;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--color-primary);
}

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

.brand-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-lavender);
}

.brand-name {
  white-space: nowrap;
}

.desktop-nav ul {
  display: flex;
  align-items: center;
  gap: .35rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  display: inline-block;
  padding: .55rem .95rem;
  border-radius: 999px;
  font-weight: 500;
  color: var(--text);
  font-size: .95rem;
  transition: background .2s, color .2s;
}

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

.nav-link.active {
  color: var(--color-primary);
  background: var(--bg-lavender);
}

.hamburger {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  padding: 0;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  border-radius: 8px;
}

.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}

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

.hamburger.is-open span:nth-child(2) {
  opacity: 0;
}

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

.mobile-menu {
  background: #fff;
  border-top: 1px solid var(--border);
  padding: 1rem;
  animation: slideDown .25s ease;
}

.mobile-menu ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: .35rem;
}

.mobile-menu .nav-link {
  display: block;
  padding: .9rem 1rem;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 4rem 0 6rem;
  overflow: hidden;
  background: linear-gradient(180deg, #FAF8FF 0%, #FFFFFF 100%);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 3rem;
  align-items: center;
}

/* ---------- Hero (continued) ---------- */
.hero-eyebrow {
  display: inline-block;
  padding: .35rem .9rem;
  border-radius: 999px;
  background: var(--bg-lavender);
  color: var(--color-primary);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .02em;
  margin-bottom: 1rem;
}

.hero h1 {
  margin-bottom: .75rem;
}

.hero-sub {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  color: var(--text-muted);
  max-width: 540px;
  margin-bottom: 1.75rem;
}

.hero-actions {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
}

.hero-visual {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 3;
  background: var(--bg-lavender);
}

.hero-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-wave {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  line-height: 0;
  pointer-events: none;
}

.hero-wave svg {
  display: block;
  width: 100%;
  height: 80px;
}

/* ---------- Section basics ---------- */
.section {
  padding: 5rem 0;
}

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 3rem;
}

.section-head h2 {
  margin-bottom: .5rem;
}

.section-head p {
  margin: 0;
}

.section-soft {
  background: var(--bg-soft);
}

/* ---------- About short block ---------- */
.about-short {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.about-short-img {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 4 / 3;
  background: var(--bg-lavender);
}

.about-short-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-short-content h2 {
  margin-bottom: 1rem;
}

.about-short-content p {
  font-size: 1.05rem;
}

/* ---------- Services grid ---------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.service-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: transform .25s, box-shadow .25s;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.service-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-sm);
  background: var(--bg-lavender);
  overflow: hidden;
  margin-bottom: 1rem;
}

.service-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s;
}

.service-card:hover .service-thumb img {
  transform: scale(1.05);
}

.service-title {
  font-size: 1.1rem;
  margin-bottom: .35rem;
}

.service-desc {
  font-size: .92rem;
  color: var(--text-muted);
  flex: 1;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.service-price {
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: .85rem;
  font-family: var(--font-head);
  font-size: 1.05rem;
}

.service-price small {
  font-weight: 500;
  color: var(--text-muted);
  font-size: .78rem;
  display: block;
}

.service-actions {
  display: flex;
  gap: .5rem;
}

.service-actions .btn {
  flex: 1;
  padding: .65rem .9rem;
  font-size: .85rem;
  min-height: 40px;
}

/* Skeleton loader */
.skeleton {
  background: linear-gradient(90deg, #f1f1f1 25%, #e8e8e8 50%, #f1f1f1 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: 8px;
}

@keyframes shimmer {
  from {
    background-position: 200% 0;
  }

  to {
    background-position: -200% 0;
  }
}

/* ---------- Reviews section ---------- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.review-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 1.75rem;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

.review-stars {
  color: #F59E0B;
  font-size: 1.05rem;
  letter-spacing: 2px;
}

.review-text {
  font-size: .95rem;
  color: var(--text-muted);
  flex: 1;
  margin: 0;
  font-style: italic;
}

.review-client {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding-top: .75rem;
  border-top: 1px solid var(--border);
}

.review-client img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-lavender);
}

.review-client strong {
  display: block;
  font-size: .92rem;
}

.review-client small {
  color: var(--text-muted);
  font-size: .8rem;
}

/* ---------- Newsletter band ---------- */
.newsletter-band {
  padding: 4rem 0;
}

.newsletter-box {
  background: linear-gradient(90deg, var(--color-primary-dark), var(--color-primary-mid) 50%, var(--color-accent));
  border-radius: 28px;
  padding: 3rem clamp(1.5rem, 5vw, 4rem);
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.newsletter-box::after {
  content: '';
  position: absolute;
  inset: -50% -20% auto auto;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
  pointer-events: none;
}

.newsletter-box h2 {
  color: #fff;
  margin-bottom: .5rem;
}

.newsletter-box p {
  color: rgba(255, 255, 255, .85);
  max-width: 520px;
  margin: 0 auto 1.75rem;
}

.newsletter-form {
  display: flex;
  gap: .5rem;
  max-width: 500px;
  margin: 0 auto;
  background: #fff;
  padding: .4rem;
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .15);
}

.newsletter-form input {
  flex: 1;
  border: none;
  padding: .85rem 1.2rem;
  border-radius: 999px;
  font-family: inherit;
  font-size: .95rem;
  min-width: 0;
  background: transparent;
  color: var(--text);
}

.newsletter-form input:focus {
  outline: none;
}

.newsletter-form button {
  border: none;
  background: var(--color-primary-dark);
  color: #fff;
  padding: .75rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .9rem;
  min-height: 44px;
  transition: background .2s;
}

.newsletter-form button:hover {
  background: var(--color-primary-mid);
}

.newsletter-msg {
  margin-top: 1rem;
  font-size: .9rem;
  min-height: 1.25rem;
}

/* ---------- Footer ---------- */
.kcs-footer {
  background: var(--color-primary-dark);
  color: rgba(255, 255, 255, .75);
  padding-top: 3.5rem;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 2.5rem;
}

.kcs-footer h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 1.25rem;
  font-family: var(--font-head);
}

.kcs-footer .brand {
  color: #fff;
}

.kcs-footer .brand-name {
  color: #fff;
}

.kcs-footer p {
  color: rgba(255, 255, 255, .7);
}

.footer-links,
.footer-contact {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: .65rem;
}

.footer-links a,
.footer-contact a {
  color: rgba(255, 255, 255, .75);
  font-size: .92rem;
  transition: color .2s;
}

.footer-links a:hover,
.footer-contact a:hover {
  color: var(--color-accent);
}

.social-row {
  display: flex;
  gap: .5rem;
  margin-top: 1.25rem;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .1);
  color: #fff;
  transition: background .2s, transform .2s;
}

.social-icon:hover {
  background: var(--color-accent);
  color: var(--color-primary-dark);
  transform: translateY(-2px);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding: 1.5rem 0;
  text-align: center;
}

.footer-bottom p {
  color: rgba(255, 255, 255, .6);
  margin: 0;
  font-size: .85rem;
}

/* ---------- WhatsApp floating button ---------- */
.kcs-whatsapp {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 90;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(37, 211, 102, .35);
  transition: transform .2s, box-shadow .2s;
}

.kcs-whatsapp:hover {
  transform: scale(1.08);
  color: #fff;
  box-shadow: 0 14px 38px rgba(37, 211, 102, .5);
}

/* ---------- Toast ---------- */
.kcs-toast {
  position: fixed;
  bottom: 90px;
  right: 1.25rem;
  background: var(--text);
  color: #fff;
  padding: .9rem 1.25rem;
  border-radius: 12px;
  font-size: .9rem;
  box-shadow: var(--shadow-lg);
  max-width: 320px;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 200;
}

.kcs-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.kcs-toast.success {
  background: #16A34A;
}

.kcs-toast.error {
  background: #DC2626;
}

.kcs-toast.info {
  background: var(--color-primary);
}

/* ---------- Fade-in animation ---------- */
[data-fade] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .6s ease, transform .6s ease;
}

[data-fade].fade-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  [data-fade] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  * {
    animation-duration: .001ms !important;
    transition-duration: .001ms !important;
  }
}

/* ---------- Forms ---------- */
.kcs-form {
  display: grid;
  gap: 1rem;
}

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

.field {
  display: grid;
  gap: .35rem;
}

.field label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: .85rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  font-family: inherit;
  font-size: .95rem;
  background: #fff;
  color: var(--text);
  transition: border-color .2s, box-shadow .2s;
  min-height: 44px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--color-primary-mid);
  box-shadow: 0 0 0 3px rgba(91, 33, 182, .12);
}

.field textarea {
  min-height: 120px;
  resize: vertical;
}

.field small {
  color: var(--text-muted);
  font-size: .78rem;
}

.field .error {
  color: #DC2626;
  font-size: .8rem;
}

/* ---------- Utility ---------- */
.text-center {
  text-align: center;
}

.mt-2 {
  margin-top: 2rem;
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Fix for Reviews Section Visibility */
#reviewsSection {
  display: block; /* Default state */
}

#reviewsSection[style*="display: none"] {
  display: none !important; /* Jab JS hide kare toh hide rahe */
}

/* Ensure the grid is visible */
#reviewsSection .reviews-grid {
  display: grid !important;
}

/* ============================================================
   CONTACT PAGE PERFECT LAYOUT
   ============================================================ */

.contact-wrapper {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: start;
  margin-top: 2rem;
}

/* Form Container */
.contact-form-wrap {
  background: #fff;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

/* Info Cards */
.contact-info-wrap {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.info-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
}

.info-card h3 {
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1rem;
}

.contact-list a {
  color: var(--color-primary);
  font-weight: 500;
  text-decoration: none;
  word-break: break-all; /* Long emails ko break karne ke liye */
}

.contact-list a:hover {
  text-decoration: underline;
}

/* Dark Card (Why choose us) */
.dark-card {
  background: var(--color-primary-dark);
  color: #fff;
  border: none;
}

.dark-card h3 {
  color: #fff;
}

.dark-list li {
  color: rgba(255,255,255,0.85);
  font-size: 0.95rem;
}

/* Inputs styling fix */
.kcs-form .field input,
.kcs-form .field select,
.kcs-form .field textarea {
  width: 100%;
  background-color: var(--bg-soft);
  border: 1.5px solid var(--border);
}

.kcs-form .field input:focus,
.kcs-form .field select:focus,
.kcs-form .field textarea:focus {
  background-color: #fff;
}

/* ============================================================
   MOBILE RESPONSIVE FIXES FOR CONTACT
   ============================================================ */
@media (max-width: 900px) {
  .contact-wrapper {
    grid-template-columns: 1fr; /* Mobile pe ek ke neeche ek aayega */
    gap: 2rem;
  }
  
  .contact-form-wrap {
    padding: 1.5rem; /* Mobile pe padding kam ki taaki jagah bache */
  }
}

@media (max-width: 640px) {
  /* Form rows ko stack karo mobile pe */
  .kcs-form .form-row {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* Buttons ko full width karo */
  .kcs-form button[type="submit"] {
    width: 100%;
  }

  /* Coupon field ko mobile pe theek karo */
  .field div[style*="display:flex"] {
    flex-direction: column;
  }
  
  .field div[style*="display:flex"] button {
    width: 100%;
  }

  /* Info card padding */
  .info-card {
    padding: 1.25rem;
  }
}