:root {
  --red: #c51f26;
  --red-dark: #9f171d;
  --navy: #101b2d;
  --text: #172033;
  --muted: #667085;
  --line: #e5e7eb;
  --surface: #f6f8fb;
  --white: #ffffff;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--white);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system,
    BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
}

.container {
  width: min(calc(100% - 40px), var(--max));
  margin-inline: auto;
}

.narrow {
  max-width: 800px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  font-size: 24px;
  letter-spacing: -.5px;
}

.brand strong {
  font-weight: 500;
}

.brand span {
  margin-left: 4px;
  padding: 1px 8px 3px;
  color: var(--white);
  background: var(--red);
  border-radius: 4px;
  font-weight: 800;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.main-nav a {
  color: #344054;
  text-decoration: none;
  font-size: 14px;
  font-weight: 650;
}

.main-nav a:hover {
  color: var(--red);
}

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(
      circle at 85% 20%,
      rgba(197, 31, 38, .12),
      transparent 28%
    ),
    linear-gradient(135deg, #f8fafc 0%, #fff 65%);
}

.hero::after {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  right: -150px;
  bottom: -220px;
  border: 70px solid rgba(197, 31, 38, .06);
  border-radius: 50%;
}

.hero-inner {
  min-height: 570px;
  display: flex;
  align-items: center;
  padding-block: 90px;
}

.hero-copy {
  position: relative;
  z-index: 1;
  max-width: 790px;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--red);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .12em;
}

.hero h1 {
  max-width: 820px;
  margin: 0;
  color: var(--navy);
  font-size: clamp(44px, 6vw, 72px);
  line-height: 1.04;
  letter-spacing: -.045em;
}

.hero-lead {
  max-width: 720px;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 36px;
}

.button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border-radius: 7px;
  text-decoration: none;
  font-weight: 750;
}

.button-primary {
  color: var(--white);
  background: var(--red);
}

.button-primary:hover {
  background: var(--red-dark);
}

.button-secondary {
  color: var(--navy);
  background: var(--white);
  border: 1px solid #d0d5dd;
}

.pillars {
  position: relative;
  z-index: 2;
  margin-top: -35px;
}

.pillar-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--navy);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(16, 24, 40, .12);
}

.pillar-grid article {
  min-height: 210px;
  padding: 34px;
  color: var(--white);
  border-right: 1px solid rgba(255, 255, 255, .12);
}

.pillar-grid article:last-child {
  border-right: 0;
}

.pillar-grid span {
  color: #ef777c;
  font-size: 12px;
  font-weight: 800;
}

.pillar-grid h2 {
  margin: 14px 0 8px;
  font-size: 23px;
}

.pillar-grid p {
  margin: 0;
  color: #c7cfdb;
  font-size: 15px;
}

.section {
  padding: 110px 0;
}

.section-alt {
  background: var(--surface);
}

.section-title {
  max-width: 760px;
  margin: 0;
  color: var(--navy);
  font-size: clamp(34px, 4vw, 48px);
  line-height: 1.12;
  letter-spacing: -.03em;
}

.section-lead {
  max-width: 700px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.placeholder {
  margin-top: 42px;
  padding: 40px;
  color: var(--muted);
  background: var(--surface);
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 46px;
}

.resource-card {
  padding: 36px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.card-label {
  margin: 0 0 12px;
  color: var(--red);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .1em;
}

.resource-card h3 {
  margin: 0;
  color: var(--navy);
  font-size: 26px;
}

.resource-card p:not(.card-label) {
  color: var(--muted);
}

.resource-card a {
  color: var(--red);
  text-decoration: none;
  font-weight: 750;
}

.community {
  text-align: center;
}

.community .container {
  margin-inline: auto;
}

.community .section-title {
  margin-inline: auto;
}

.community p:last-child {
  color: var(--muted);
  font-size: 18px;
}

.site-footer {
  padding: 60px 0 25px;
  color: #d0d5dd;
  background: #0b1422;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 40px;
}

.footer-inner strong {
  color: var(--white);
  font-size: 22px;
}

.footer-inner p {
  margin: 8px 0 0;
  color: #98a2b3;
}

.footer-inner div:last-child {
  display: flex;
  gap: 24px;
}

.footer-inner a {
  text-decoration: none;
}

.footer-inner a:hover {
  color: var(--white);
}

.copyright {
  margin-top: 45px;
  padding-top: 22px;
  color: #667085;
  border-top: 1px solid #263244;
  font-size: 13px;
}

@media (max-width: 760px) {
  .header-inner {
    min-height: 66px;
  }

  .main-nav {
    display: none;
  }

  .hero-inner {
    min-height: auto;
    padding-block: 80px 100px;
  }

  .hero h1 {
    font-size: clamp(40px, 12vw, 56px);
  }

  .hero-lead {
    font-size: 18px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .pillars {
    margin-top: -25px;
  }

  .pillar-grid {
    grid-template-columns: 1fr;
  }

  .pillar-grid article {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .12);
  }

  .pillar-grid article:last-child {
    border-bottom: 0;
  }

  .section {
    padding: 80px 0;
  }

  .resource-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
  }
}

/* =========================================================
   SeaCCNA Homepage V2
   Training, ebook, testimonials and contact
   ========================================================= */

.training {
  background: #fff;
}

.course-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 48px;
}

.course-card {
  position: relative;
  min-height: 285px;
  display: flex;
  flex-direction: column;
  padding: 30px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  transition:
    transform .2s ease,
    box-shadow .2s ease,
    border-color .2s ease;
}

.course-card:hover {
  transform: translateY(-4px);
  border-color: #d0d5dd;
  box-shadow: 0 18px 40px rgba(16, 24, 40, .09);
}

.course-type {
  margin-bottom: 18px;
  color: var(--red);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .1em;
}

.course-card h3 {
  margin: 0;
  color: var(--navy);
  font-size: 23px;
  line-height: 1.2;
}

.course-card p {
  margin: 16px 0 24px;
  color: var(--muted);
  font-size: 15px;
}

.course-card a {
  margin-top: auto;
  color: var(--red);
  text-decoration: none;
  font-size: 14px;
  font-weight: 750;
}

.ebook-section {
  padding: 100px 0;
  color: #fff;
  background:
    radial-gradient(
      circle at 80% 20%,
      rgba(197, 31, 38, .22),
      transparent 30%
    ),
    var(--navy);
}

.ebook-layout {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 80px;
  align-items: center;
}

.ebook-copy {
  max-width: 620px;
}

.ebook-copy h2 {
  margin: 0;
  font-size: clamp(38px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -.035em;
}

.ebook-copy > p:not(.eyebrow) {
  max-width: 560px;
  margin: 24px 0 32px;
  color: #c7cfdb;
  font-size: 18px;
}

.ebook-visual {
  width: min(100%, 390px);
  aspect-ratio: 4 / 3;
  justify-self: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 48px;
  color: var(--navy);
  background: #fff;
  border-radius: 14px;
  box-shadow: 28px 28px 0 rgba(197, 31, 38, .7);
  transform: rotate(2deg);
}

.ebook-visual span {
  color: var(--red);
  font-size: 84px;
  font-weight: 850;
  line-height: .8;
}

.ebook-visual strong {
  margin-top: 12px;
  font-size: 42px;
  line-height: 1;
}

.ebook-visual small {
  margin-top: 12px;
  color: var(--muted);
  font-size: 16px;
}

.testimonials {
  background: #fff;
}

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 48px;
}

.testimonial-grid blockquote {
  margin: 0;
  padding: 34px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.testimonial-grid blockquote::before {
  content: "“";
  display: block;
  height: 36px;
  color: var(--red);
  font-family: Georgia, serif;
  font-size: 58px;
  line-height: .8;
}

.testimonial-grid blockquote p {
  margin: 18px 0 26px;
  color: var(--navy);
  font-size: 18px;
  line-height: 1.6;
}

.testimonial-grid blockquote footer {
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.contact-section {
  padding: 90px 0;
  color: #fff;
  background: #111c2e;
}

.contact-layout {
  display: grid;
  grid-template-columns: 1.3fr .7fr;
  gap: 70px;
  align-items: center;
}

.contact-section h2 {
  max-width: 650px;
  margin: 0;
  font-size: clamp(36px, 4vw, 50px);
  line-height: 1.1;
  letter-spacing: -.03em;
}

.contact-section p:not(.eyebrow) {
  max-width: 620px;
  margin: 20px 0 0;
  color: #c7cfdb;
  font-size: 18px;
}

.contact-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.contact-email {
  color: #fff;
  text-decoration: none;
  font-weight: 650;
}

.contact-email:hover {
  text-decoration: underline;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 24px;
}

@media (max-width: 1000px) {
  .course-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .ebook-layout {
    gap: 50px;
  }
}

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

  .course-card {
    min-height: auto;
  }

  .ebook-section {
    padding: 80px 0 95px;
  }

  .ebook-layout {
    grid-template-columns: 1fr;
  }

  .ebook-visual {
    width: calc(100% - 28px);
    margin-right: 28px;
    justify-self: start;
  }

  .testimonial-grid {
    grid-template-columns: 1fr;
  }

  .contact-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .contact-actions {
    width: 100%;
  }

  .contact-actions .button {
    width: 100%;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

/* =========================================================
   Official SeaCCNA brand
   ========================================================= */

.brand-logo {
  display: block;
  width: 148px;
  line-height: 0;
}

.brand-logo img {
  display: block;
  width: 100%;
  height: auto;
}

.footer-brand > img {
  display: block;
  width: 160px;
  height: auto;
  margin: 0 0 12px;
}

.footer-brand p {
  margin-top: 0;
}

@media (max-width: 760px) {
  .brand-logo {
    width: 145px;
  }

  .footer-brand > img {
    width: 148px;
  }
}

/* =========================================================
   Course cards — normalized cover layout
   ========================================================= */

.course-card {
  display: flex;
  flex-direction: column;
  min-height: 500px;
  overflow: hidden;
}

.course-card .course-copy {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.course-card .course-copy p {
  margin-bottom: 18px;
}

.course-card .course-copy a {
  margin-top: auto;
}

.course-card .course-cover {
  display: block;
  width: auto;
  height: 230px;
  max-width: 90%;
  object-fit: contain;
  object-position: center bottom;
  margin: 18px auto 0;
  flex-shrink: 0;
}

@media (max-width: 760px) {
  .course-card {
    min-height: 0;
  }

  .course-card .course-cover {
    height: 210px;
    max-width: 86%;
    margin-top: 20px;
  }
}

/* Course cards — final compact refinement */
.course-card {
  min-height: 470px;
}

.course-card .course-cover {
  height: 205px;
}

@media (max-width: 760px) {
  .course-card {
    min-height: 0;
  }

  .course-card .course-cover {
    height: 190px;
  }
}

/* =========================================================
   Ebook — real cover
   ========================================================= */
.ebook-visual {
  width: min(100%, 460px);
  aspect-ratio: auto;
  padding: 0;
  background: transparent;
  box-shadow: none;
  transform: none;
}

.ebook-visual img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 24px 55px rgba(15, 23, 42, .18);
}

@media (max-width: 760px) {
  .ebook-visual {
    width: 100%;
    max-width: 460px;
    margin-right: 0;
    justify-self: center;
  }
}

/* Ebook — final size refinement */
.ebook-visual {
  width: min(100%, 500px);
}

@media (max-width: 760px) {
  .ebook-visual {
    max-width: 460px;
  }
}

/* =========================================================
   Mobile navigation
   ========================================================= */

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  margin: 5px auto;
  background: var(--navy);
  border-radius: 2px;
}

@media (max-width: 760px) {
  .header-inner {
    position: relative;
  }

  .menu-toggle {
    display: block;
    flex-shrink: 0;
  }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;

    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;

    padding: 8px 20px 16px;
    background: #fff;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 24px rgba(15, 23, 42, .10);
  }

  .main-nav.is-open {
    display: flex;
  }

  .main-nav a {
    display: block;
    padding: 13px 4px;
    border-bottom: 1px solid var(--line);
    font-size: 15px;
  }

  .main-nav a:last-child {
    border-bottom: 0;
  }
}
