/* ============================================
   Tələbə Mərkəzi — Design System
   ============================================ */

:root {
  --primary-dark: #1e293b;
  --primary-blue: #3b82f6;
  --primary-blue-hover: #2563eb;
  --accent-green: #10b981;
  --accent-green-hover: #059669;
  --bg-light: #f8fafc;
  --bg-white: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 16px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.12);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --header-h: 72px;
  --container: 1180px;
  --transition: 0.22s ease;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text-main);
  background: var(--bg-light);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

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

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.2;
  transition: background var(--transition), color var(--transition),
    box-shadow var(--transition), transform var(--transition);
  white-space: nowrap;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--primary-blue);
  color: #fff;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.28);
}

.btn-primary:hover {
  background: var(--primary-blue-hover);
}

.btn-secondary {
  background: #fff;
  color: var(--primary-dark);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  border-color: var(--primary-blue);
  color: var(--primary-blue);
}

.btn-green {
  background: var(--accent-green);
  color: #fff;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.28);
}

.btn-green:hover {
  background: var(--accent-green-hover);
}

.btn-ghost {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-block {
  width: 100%;
}

.btn-sm {
  padding: 0.5rem 0.9rem;
  font-size: 0.85rem;
}

/* ---------- Badges ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.badge-blue {
  background: #dbeafe;
  color: #1d4ed8;
}

.badge-green {
  background: #d1fae5;
  color: #047857;
}

.badge-amber {
  background: #fef3c7;
  color: #b45309;
}

.badge-slate {
  background: #e2e8f0;
  color: #334155;
}

.badge-rose {
  background: #ffe4e6;
  color: #be123c;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #fff;
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--primary-dark);
  flex-shrink: 0;
}

.logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary-blue), #1d4ed8);
  color: #fff;
  display: grid;
  place-items: center;
}

.logo-icon svg {
  width: 22px;
  height: 22px;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid var(--border-color);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--primary-dark);
  border-radius: 2px;
  transition: var(--transition);
}

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

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

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

.nav {
  position: fixed;
  inset: var(--header-h) 0 0 auto;
  width: min(86vw, 320px);
  background: #fff;
  border-left: 1px solid var(--border-color);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transform: translateX(100%);
  transition: transform var(--transition);
  box-shadow: var(--shadow-lg);
  z-index: 90;
}

.nav.is-open {
  transform: translateX(0);
}

.nav a {
  padding: 0.7rem 0.85rem;
  border-radius: 8px;
  color: var(--text-main);
  font-weight: 500;
  font-size: 0.95rem;
}

.nav a:hover,
.nav a.active {
  background: var(--bg-light);
  color: var(--primary-blue);
}

.nav a.nav-cta,
.nav a.nav-cta:hover {
  background: var(--primary-blue);
  color: #fff;
  text-align: center;
}

.header-cta {
  display: none;
}

.nav-cta {
  margin-top: 0.75rem;
}

.nav-overlay {
  display: none;
  position: fixed;
  inset: var(--header-h) 0 0 0;
  background: rgba(15, 23, 42, 0.4);
  z-index: 80;
}

.nav-overlay.is-open {
  display: block;
}

@media (min-width: 960px) {
  .nav-toggle,
  .nav-overlay {
    display: none;
  }

  .nav {
    position: static;
    width: auto;
    flex-direction: row;
    align-items: center;
    transform: none;
    padding: 0;
    border: 0;
    box-shadow: none;
    gap: 0.15rem;
  }

  .nav a {
    padding: 0.5rem 0.7rem;
    font-size: 0.875rem;
  }

  .header-cta {
    display: inline-flex;
  }

  .nav-cta {
    display: none;
  }
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(145deg, #0f172a 0%, #1e3a5f 55%, #1d4ed8 100%);
  color: #fff;
  padding: 3.5rem 0 4rem;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.25);
  right: -80px;
  bottom: -140px;
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: clamp(1.75rem, 4.5vw, 2.75rem);
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 0.85rem;
}

.hero p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
  max-width: 560px;
}

.hero-search {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  background: #fff;
  padding: 0.5rem;
  border-radius: 12px;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-lg);
}

.hero-search input {
  width: 100%;
  border: 0;
  padding: 0.75rem 1rem;
  color: var(--text-main);
  outline: none;
}

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

@media (min-width: 640px) {
  .hero-search {
    flex-direction: row;
    align-items: center;
  }

  .hero-search input {
    flex: 1;
  }
}

/* ---------- Sections ---------- */
.section {
  padding: 3.5rem 0;
}

.section-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
}

.section-kicker {
  color: var(--primary-blue);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.35rem;
}

.section-header h2,
.page-hero h1 {
  font-size: clamp(1.45rem, 3vw, 1.9rem);
  letter-spacing: -0.02em;
}

.section-header p {
  color: var(--text-muted);
  max-width: 480px;
}

.page-hero {
  background: #fff;
  border-bottom: 1px solid var(--border-color);
  padding: 2rem 0;
}

.page-hero p {
  color: var(--text-muted);
  margin-top: 0.4rem;
  max-width: 640px;
}

/* ---------- Cards / Grids ---------- */
.grid-6 {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

.service-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
  height: 100%;
}

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

.service-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  margin-bottom: 0.9rem;
  color: #fff;
}

.service-icon svg {
  width: 22px;
  height: 22px;
}

.service-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
}

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

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.85rem;
  color: var(--primary-blue);
  font-weight: 600;
  font-size: 0.875rem;
}

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

.listing-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.listing-media {
  height: 150px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 0.75rem;
  color: #fff;
  font-weight: 700;
}

.listing-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.listing-body h3 {
  font-size: 1rem;
}

.price {
  font-weight: 800;
  color: var(--primary-dark);
  font-size: 1.1rem;
}

.listing-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.25rem 0 0.5rem;
}

.listing-body .btn {
  margin-top: auto;
}

@media (min-width: 640px) {
  .grid-6 {
    grid-template-columns: repeat(2, 1fr);
  }

  .listing-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .grid-6 {
    grid-template-columns: repeat(3, 1fr);
  }

  .listing-grid.cols-4 {
    grid-template-columns: repeat(4, 1fr);
  }

  .listing-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---------- FAQ ---------- */
.faq-list {
  display: grid;
  gap: 0.75rem;
  max-width: 800px;
}

.faq-item {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.faq-q {
  width: 100%;
  text-align: left;
  padding: 1rem 1.15rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-weight: 600;
  color: var(--text-main);
}

.faq-q::after {
  content: "+";
  font-size: 1.25rem;
  color: var(--primary-blue);
  flex-shrink: 0;
}

.faq-item.is-open .faq-q::after {
  content: "–";
}

.faq-a {
  display: none;
  padding: 0 1.15rem 1.1rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.faq-item.is-open .faq-a {
  display: block;
}

/* ---------- Split layout (transfer) ---------- */
.split {
  display: grid;
  gap: 1.5rem;
}

.info-block {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-sm);
}

.info-block h2 {
  font-size: 1.2rem;
  margin-bottom: 0.85rem;
}

.info-block h3 {
  font-size: 1rem;
  margin: 1rem 0 0.5rem;
}

.info-block p,
.info-block li {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.info-block ul,
.info-block ol {
  display: grid;
  gap: 0.45rem;
  padding-left: 1.1rem;
}

.info-block ul {
  list-style: disc;
}

.info-block ol {
  list-style: decimal;
}

.callout {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--primary-blue);
  border-radius: var(--radius-md);
  padding: 1.15rem 1.25rem;
}

.callout strong {
  display: block;
  margin-bottom: 0.3rem;
  color: var(--primary-dark);
}

.callout p {
  color: #1e3a5f;
  font-size: 0.92rem;
}

.sticky-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
}

@media (min-width: 900px) {
  .split {
    grid-template-columns: 1.65fr 1fr;
    align-items: start;
  }

  .sticky-card {
    position: sticky;
    top: calc(var(--header-h) + 1.25rem);
  }
}

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

.form-row {
  display: grid;
  gap: 0.9rem;
}

@media (min-width: 640px) {
  .form-row.two {
    grid-template-columns: 1fr 1fr;
  }
}

.field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--primary-dark);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--border-color);
  background: var(--bg-light);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.85rem;
  color: var(--text-main);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

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

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--primary-blue);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.radio-chip {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid var(--border-color);
  background: var(--bg-light);
  border-radius: var(--radius-full);
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 500;
}

.radio-chip:has(input:checked) {
  border-color: var(--primary-blue);
  background: #eff6ff;
  color: var(--primary-blue);
}

.dropzone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem 1rem;
  text-align: center;
  background: var(--bg-light);
  color: var(--text-muted);
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
}

.dropzone.is-dragover {
  border-color: var(--primary-blue);
  background: #eff6ff;
}

.dropzone strong {
  display: block;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

.dropzone input {
  display: none;
}

.file-name {
  margin-top: 0.5rem;
  font-size: 0.82rem;
  color: var(--accent-green);
  font-weight: 600;
}

.note-banner {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
  border-radius: var(--radius-md);
  padding: 0.9rem 1rem;
  font-size: 0.9rem;
  margin-bottom: 1.1rem;
}

/* ---------- Tabs ---------- */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  background: #fff;
  border: 1px solid var(--border-color);
  padding: 0.45rem;
  border-radius: 12px;
  margin-bottom: 1.5rem;
  width: fit-content;
  max-width: 100%;
}

.tab-btn {
  padding: 0.6rem 1rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.tab-btn.is-active {
  background: var(--primary-blue);
  color: #fff;
}

.tab-panel {
  display: none;
}

.tab-panel.is-active {
  display: block;
}

/* ---------- Filters ---------- */
.filters-bar {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

@media (min-width: 720px) {
  .filters-bar.inline {
    grid-template-columns: 1.4fr 1fr 1fr auto;
    align-items: end;
  }
}

.housing-layout {
  display: grid;
  gap: 1.25rem;
}

.filter-sidebar {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.2rem;
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 0.9rem;
  height: fit-content;
}

.filter-sidebar h3 {
  font-size: 1rem;
}

@media (min-width: 900px) {
  .housing-layout {
    grid-template-columns: 260px 1fr;
    align-items: start;
  }

  .filter-sidebar {
    position: sticky;
    top: calc(var(--header-h) + 1rem);
  }
}

/* ---------- Career ---------- */
.career-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

.job-card,
.blog-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.2rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.job-top {
  display: flex;
  gap: 0.85rem;
  align-items: center;
}

.logo-mark {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  flex-shrink: 0;
}

.job-card h3,
.blog-card h3 {
  font-size: 1.02rem;
}

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

@media (min-width: 720px) {
  .career-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .career-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.consult-wrap {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 860px) {
  .consult-wrap {
    grid-template-columns: 1fr 1.1fr;
    align-items: center;
  }
}

.consult-copy h2 {
  margin: 0.35rem 0 0.6rem;
}

.consult-copy p {
  color: var(--text-muted);
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: auto;
  background: var(--primary-dark);
  color: #cbd5e1;
  padding: 3rem 0 1.25rem;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  margin-bottom: 2rem;
}

.footer-brand h3 {
  color: #fff;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-brand p {
  font-size: 0.9rem;
  max-width: 320px;
}

.footer-grid h4 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 0.8rem;
}

.footer-grid a {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.45rem;
}

.footer-grid a:hover {
  color: #fff;
}

.socials {
  display: flex;
  gap: 0.5rem;
}

.socials a {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  display: grid;
  place-items: center;
  margin: 0;
}

.socials a:hover {
  background: var(--primary-blue);
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.1rem;
  font-size: 0.82rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
}

@media (min-width: 720px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
  }
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  transform: translateX(-50%) translateY(120%);
  background: var(--primary-dark);
  color: #fff;
  padding: 0.85rem 1.2rem;
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  z-index: 200;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.toast-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-green);
}

/* ---------- Cover placeholders ---------- */
.cover-1 { background: linear-gradient(135deg, #1e3a8a, #3b82f6); }
.cover-2 { background: linear-gradient(135deg, #064e3b, #10b981); }
.cover-3 { background: linear-gradient(135deg, #7c2d12, #f59e0b); }
.cover-4 { background: linear-gradient(135deg, #4c1d95, #8b5cf6); }
.cover-5 { background: linear-gradient(135deg, #0e7490, #22d3ee); }
.cover-6 { background: linear-gradient(135deg, #9f1239, #fb7185); }
.cover-7 { background: linear-gradient(135deg, #1e293b, #64748b); }
.cover-8 { background: linear-gradient(135deg, #365314, #84cc16); }

.hidden {
  display: none !important;
}
