/* British Academic Helps Global CSS */
:root {
  --primary: #0B1F4D;
  --secondary: #C8102E;
  --accent: #D4AF37;
  --light: #F7F9FC;
  --text: #1F2937;
  --white: #FFFFFF;
  --muted: #6B7280;
  --border: #E5E7EB;
  --success: #047857;
  --danger: #B91C1C;
  --shadow: 0 14px 35px rgba(11, 31, 77, 0.12);
  --radius: 18px;
  --container: 1180px;
  --heading-font: Georgia, "Times New Roman", serif;
  --body-font: Inter, Lato, Poppins, Arial, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--body-font);
  color: var(--text);
  background: var(--white);
  line-height: 1.65;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.container {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
}

h1,
h2,
h3,
h4 {
  font-family: var(--heading-font);
  color: var(--primary);
  line-height: 1.18;
  margin: 0 0 14px;
}

h1 { font-size: clamp(2.2rem, 5vw, 4.2rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.6rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 16px; }

.section {
  padding: 80px 0;
}

.section-light {
  background: var(--light);
}

.text-muted {
  color: var(--muted);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.7);
  transition: box-shadow 0.25s ease;
}

.site-header.is-scrolled {
  box-shadow: 0 8px 24px rgba(11, 31, 77, 0.1);
}

.header-inner {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--primary);
}

.site-logo {
  max-height: 54px;
  width: auto;
}

.text-logo {
  font-family: var(--heading-font);
  font-size: 1.35rem;
  font-weight: 700;
}

.primary-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 4px;
}

.primary-nav a,
.dropdown-toggle {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 10px 13px;
  color: var(--primary);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-weight: 650;
  border-radius: 12px;
}

.primary-nav a:hover,
.dropdown-toggle:hover,
.has-dropdown.is-open > .dropdown-toggle {
  background: var(--light);
  color: var(--secondary);
}

.has-dropdown {
  position: relative;
}

.dropdown-toggle::after {
  content: "▾";
  font-size: 0.8rem;
  margin-left: 7px;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  min-width: 260px;
  padding: 12px;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  border-radius: 16px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: 0.2s ease;
}

.has-dropdown:hover .dropdown-menu,
.has-dropdown.is-open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu a {
  display: block;
  min-height: auto;
  padding: 10px 12px;
  font-size: 0.95rem;
}

.dropdown-grid {
  min-width: 520px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mobile-menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--white);
  cursor: pointer;
  padding: 9px;
}

.mobile-menu-toggle span {
  display: block;
  height: 2px;
  background: var(--primary);
  margin: 6px 0;
  transition: 0.2s ease;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 800;
  cursor: pointer;
  transition: 0.2s ease;
}

.btn-primary {
  background: var(--secondary);
  color: var(--white) !important;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(200, 16, 46, 0.25);
}

.btn-secondary {
  background: var(--primary);
  color: var(--white);
}

.btn-accent {
  background: var(--accent);
  color: var(--primary);
}

.btn-outline {
  border-color: var(--primary);
  color: var(--primary);
  background: transparent;
}

.nav-cta {
  margin-left: 6px;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 92px 0;
  background:
    radial-gradient(circle at 15% 15%, rgba(212,175,55,0.2), transparent 32%),
    linear-gradient(135deg, var(--light), #fff);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 44px;
  align-items: center;
}

.hero-label {
  display: inline-flex;
  margin-bottom: 16px;
  color: var(--secondary);
  font-weight: 800;
}

.hero p {
  font-size: 1.08rem;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 24px;
}

.card,
.service-card,
.subject-card,
.pricing-card,
.faq-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(11,31,77,0.06);
}

.card {
  padding: 28px;
}

.cards-grid,
.service-grid,
.subject-grid,
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.service-card,
.subject-card,
.pricing-card {
  padding: 26px;
  transition: 0.2s ease;
}

.service-card:hover,
.subject-card:hover,
.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.pricing-card.featured {
  border-color: var(--accent);
  position: relative;
}

.price {
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--primary);
}

.form-card,
.admin-card {
  background: var(--white);
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.form-group {
  margin-bottom: 18px;
}

label {
  display: block;
  margin-bottom: 7px;
  font-weight: 750;
  color: var(--primary);
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 13px 14px;
  color: var(--text);
  background: var(--white);
  outline: none;
  transition: 0.2s ease;
}

textarea {
  min-height: 140px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(11,31,77,0.08);
}

.form-error {
  color: var(--danger);
  font-size: 0.9rem;
  margin-top: 6px;
}

.faq-list {
  display: grid;
  gap: 14px;
}

.faq-item {
  overflow: hidden;
}

.faq-question {
  width: 100%;
  padding: 20px 22px;
  background: var(--white);
  border: 0;
  text-align: left;
  color: var(--primary);
  font-weight: 850;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.faq-question::after {
  content: "+";
  font-size: 1.4rem;
  color: var(--secondary);
}

.faq-item.is-open .faq-question::after {
  content: "−";
}

.faq-answer {
  display: none;
  padding: 0 22px 20px;
  color: var(--muted);
}

.faq-item.is-open .faq-answer {
  display: block;
}

.cta-section {
  background: linear-gradient(135deg, var(--primary), #153875);
  color: var(--white);
  padding: 70px 0;
}

.cta-section h2,
.cta-section h3 {
  color: var(--white);
}

.cta-box {
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}

.admin-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
  background: var(--light);
}

.admin-sidebar {
  background: var(--primary);
  color: var(--white);
  padding: 24px;
}

.admin-sidebar a {
  display: block;
  padding: 11px 12px;
  border-radius: 10px;
  color: var(--white);
}

.admin-sidebar a:hover {
  background: rgba(255,255,255,0.12);
}

.admin-main {
  padding: 30px;
}

.table-responsive {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: 14px;
  overflow: hidden;
}

th,
td {
  padding: 14px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

th {
  background: var(--primary);
  color: var(--white);
}

.site-footer {
  background: #071633;
  color: rgba(255,255,255,0.85);
  padding-top: 64px;
}

.site-footer h2,
.site-footer h3 {
  color: var(--white);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 30px;
}

.footer-links a,
.footer-contact a {
  display: block;
  color: rgba(255,255,255,0.78);
  margin-bottom: 10px;
}

.footer-links a:hover,
.footer-contact a:hover {
  color: var(--accent);
}

.footer-policy {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 30px 0;
  border-top: 1px solid rgba(255,255,255,0.12);
  margin-top: 34px;
}

.footer-policy a {
  color: rgba(255,255,255,0.78);
}

.footer-bottom {
  background: rgba(0,0,0,0.25);
  padding: 16px 0;
  text-align: center;
}

@media (max-width: 1024px) {
  .mobile-menu-toggle {
    display: inline-block;
  }

  .primary-nav {
    position: absolute;
    top: 78px;
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
    display: none;
  }

  .primary-nav.is-open {
    display: block;
  }

  .primary-nav ul {
    display: block;
    padding: 14px 16px 22px;
  }

  .primary-nav a,
  .dropdown-toggle {
    width: 100%;
    justify-content: space-between;
  }

  .dropdown-menu,
  .dropdown-grid {
    position: static;
    min-width: 0;
    box-shadow: none;
    border: 0;
    padding: 4px 0 8px 14px;
    opacity: 1;
    visibility: visible;
    transform: none;
    display: none;
    grid-template-columns: 1fr;
  }

  .has-dropdown.is-open .dropdown-menu {
    display: grid;
  }

  .nav-cta {
    margin-left: 0;
    margin-top: 8px;
    justify-content: center !important;
  }

  .hero-grid,
  .cards-grid,
  .service-grid,
  .subject-grid,
  .pricing-grid,
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .container {
    width: min(100% - 24px, var(--container));
  }

  .section {
    padding: 56px 0;
  }

  .hero {
    padding: 64px 0;
  }

  .hero-grid,
  .cards-grid,
  .service-grid,
  .subject-grid,
  .pricing-grid,
  .form-grid,
  .footer-grid,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .footer-policy {
    flex-direction: column;
  }

  .admin-sidebar {
    position: static;
  }
}
