/* Base styles */
* { box-sizing: border-box; }
:root {
  --navy: #082f4a;
  --navy-deep: #06253a;
  --teal: #0a7898;
  --teal-soft: #dfeef3;
  --ink: #173247;
  --muted: #4c6679;
  --line: #d7e4ea;
  --paper: #f7f9fa;
  --white: #ffffff;
}

body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--ink);
  background-color: var(--paper);
  line-height: 1.6;
}

a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.25rem;
  padding: 1rem 2rem;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
}

.brand-mark {
  width: 58px;
  height: 58px;
  object-fit: contain;
  display: block;
  flex: 0 0 auto;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.brand-title {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.85rem;
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--navy);
  white-space: nowrap;
}

.brand-subtitle {
  font-size: 0.9rem;
  color: var(--muted);
  white-space: nowrap;
}

nav .nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.35rem;
}

nav .nav-links a {
  color: var(--navy);
  font-weight: 600;
  letter-spacing: 0.01em;
}

nav .nav-links a:hover {
  text-decoration: none;
  color: var(--teal);
}

nav .nav-links .lang-toggle {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.28rem 0.75rem;
}

nav .nav-links .lang-toggle:hover {
  background: var(--teal-soft);
}

/* Home hero */
.hero {
  position: relative;
  background: linear-gradient(180deg, #071f33 0%, #0b3148 100%);
  color: var(--white);
  overflow: hidden;
}

.hero-banner {
  width: 100%;
  background: #061827;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}

.hero-banner img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 360px;
  object-fit: contain;
  object-position: center;
}

.hero .overlay {
  display: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 2rem 2rem 2.6rem;
}

.hero-card {
  max-width: 680px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  backdrop-filter: blur(5px);
  border-radius: 16px;
  padding: 1.55rem 1.6rem;
  box-shadow: 0 18px 40px rgba(0,0,0,0.2);
}

.hero-content h1 {
  font-size: 2.75rem;
  line-height: 1.08;
  margin: 0 0 0.55rem;
}

.hero-content p {
  font-size: 1.08rem;
  margin: 0 0 1rem;
  color: rgba(255,255,255,0.94);
}

.cta {
  display: inline-block;
  background-color: var(--teal);
  color: var(--white);
  padding: 0.78rem 1.35rem;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: 0 10px 22px rgba(8,47,74,0.14);
}

.cta:hover {
  background-color: #095d77;
  text-decoration: none;
}

/* Page hero */
.page-hero {
  position: relative;
  background: linear-gradient(90deg, rgba(6,37,58,0.97) 0%, rgba(8,47,74,0.9) 58%, rgba(8,47,74,0.82) 100%);
  color: var(--white);
}

.page-hero .section {
  padding-top: 3rem;
  padding-bottom: 3rem;
}

.page-hero h1,
.page-hero h2 {
  margin: 0 0 0.5rem;
  font-size: 2.6rem;
  line-height: 1.08;
  color: var(--white);
  max-width: 720px;
}

.page-hero p {
  margin: 0;
  max-width: 760px;
  font-size: 1.12rem;
  color: rgba(255,255,255,0.94);
}

/* Sections */
.section {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 3rem 2rem;
}

.section h2 {
  font-size: 2rem;
  margin: 0 0 1rem;
  color: var(--navy);
}

.section p {
  font-size: 1rem;
  color: var(--ink);
}

.research {
  padding-top: 3.4rem;
}

.portal {
  background-color: #eef5f7;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.portal .section-inner,
.contact .section-inner {
  max-width: 1080px;
}

.portal.centered {
  text-align: center;
  padding-top: 3.5rem;
  padding-bottom: 3.6rem;
}

.portal.centered h2 {
  margin-bottom: 0.5rem;
}

.portal.centered p {
  max-width: 920px;
  margin: 0 auto 1.35rem;
}

.contact {
  padding-bottom: 4rem;
}

/* About page bio layout */
.bio-layout {
  display: grid;
  grid-template-columns: minmax(320px, 620px) minmax(300px, 1fr);
  gap: 2.25rem;
  align-items: start;
  margin-top: 1.3rem;
}

.bio-figure {
  margin: 0;
}

.bio-figure img {
  display: block;
  width: 100%;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 12px 28px rgba(7, 37, 58, 0.12);
}

.eyebrow {
  display: inline-block;
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.6rem;
}

.eyebrow::after {
  content: "";
  display: block;
  width: 46px;
  height: 3px;
  background: var(--teal);
  margin-top: 0.5rem;
  border-radius: 999px;
}

.bio-copy h2 {
  font-size: 3rem;
  line-height: 1.04;
  margin: 0 0 1rem;
}

.bio-copy p {
  font-size: 1.02rem;
  margin: 0 0 1rem;
}

.bio-copy .cta {
  margin-top: 0.4rem;
  background-color: var(--navy);
}

.bio-copy .cta:hover {
  background-color: var(--navy-deep);
}

/* Panels */
.card-panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.35rem 1.35rem 1.15rem;
  box-shadow: 0 10px 24px rgba(7,37,58,0.05);
}

/* Footer */
.site-footer {
  background: var(--navy);
  color: var(--white);
  margin-top: 0;
}

.footer-inner {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 1.6rem 2rem 0.9rem;
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  align-items: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.footer-brand img {
  width: 50px;
  height: 50px;
  object-fit: contain;
  display: block;
}

.footer-title {
  font-weight: 700;
  font-size: 1.15rem;
}

.footer-sub {
  color: rgba(255,255,255,0.82);
  font-size: 0.95rem;
}

.footer-meta {
  text-align: right;
}

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

.footer-copy {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 0 2rem 1.2rem;
  color: rgba(255,255,255,0.8);
  font-size: 0.95rem;
}

@media (max-width: 940px) {
  nav {
    flex-direction: column;
    align-items: flex-start;
  }

  nav .nav-links {
    margin-top: 0.5rem;
    gap: 1rem;
  }

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

  .bio-copy h2 {
    font-size: 2.35rem;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-meta {
    text-align: left;
  }
}

@media (max-width: 700px) {
  .brand-title {
    font-size: 1.45rem;
  }

  .brand-subtitle {
    white-space: normal;
  }

  .hero-content {
    padding: 0 1rem 1.5rem;
  }

  .hero-card {
    padding: 1.15rem 1.1rem;
  }

  .hero-content h1,
  .page-hero h1,
  .page-hero h2 {
    font-size: 2rem;
  }

  .section {
    padding: 2.2rem 1rem;
  }

  .brand-mark {
    width: 52px;
    height: 52px;
  }
}


/* COGSEC CANADA logo/slogan refinement */
.brand-mark{width:58px;height:58px;object-fit:contain;}
.footer-brand img{width:50px;height:50px;object-fit:contain;}
.brand-subtitle,.footer-sub{letter-spacing:0.01em;font-weight:500;}
.brand-title,.footer-title{letter-spacing:0.015em;}

/* Main logo replacement: full bilingual Cognitive Security Canada mark */
.brand-logo {
  width: min(430px, 48vw);
  height: auto;
  object-fit: contain;
  display: block;
  flex: 0 1 auto;
}

.footer-logo {
  width: min(320px, 70vw);
  height: auto;
  object-fit: contain;
  display: block;
  background: var(--white);
  border-radius: 4px;
}

@media (max-width: 700px) {
  .brand-logo {
    width: min(330px, 82vw);
  }
}


/* Footer logo update: transparent bilingual mark on left, location line on right */
.footer-logo {
  width: min(540px, 78vw);
  height: auto;
  object-fit: contain;
  display: block;
  background: transparent !important;
  border-radius: 0 !important;
}
.footer-brand {
  min-width: 0;
}
.footer-meta div:last-child {
  letter-spacing: 0.01em;
}
@media (max-width: 700px) {
  .footer-logo {
    width: min(390px, 92vw);
  }
}


/* Final logo/header/footer update */
.brand-logo {
  width: min(360px, 42vw);
  max-height: 105px;
  object-fit: contain;
}
.footer-text-brand {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
}
.footer-text-brand .footer-title {
  color: var(--white);
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
}
.footer-text-brand .footer-sub {
  color: rgba(255,255,255,0.84);
  font-size: 0.96rem;
  letter-spacing: 0.01em;
}
@media (max-width: 700px) {
  .brand-logo {
    width: min(300px, 78vw);
    max-height: 95px;
  }
}

/* Header logo readability update: larger full bilingual mark on all pages */
.brand-logo {
  width: min(620px, 58vw) !important;
  max-height: 165px !important;
  height: auto !important;
  object-fit: contain !important;
  display: block !important;
}

nav {
  padding: 0.85rem 2rem !important;
}

@media (max-width: 1100px) {
  .brand-logo {
    width: min(560px, 92vw) !important;
    max-height: 150px !important;
  }
}

@media (max-width: 700px) {
  .brand-logo {
    width: min(440px, 92vw) !important;
    max-height: 130px !important;
  }
}

/* Header logo enlargement + upper-left placement update */
nav {
  justify-content: flex-start !important;
  align-items: flex-start !important;
  padding: 0.25rem 1rem 0.55rem 0.75rem !important;
  gap: 1rem !important;
}

.brand {
  align-self: flex-start !important;
  margin: 0 !important;
  flex: 0 0 auto !important;
}

.brand-logo {
  width: min(820px, 64vw) !important;
  max-height: 225px !important;
  height: auto !important;
  object-fit: contain !important;
  object-position: left top !important;
  display: block !important;
}

nav .nav-links {
  margin-left: auto !important;
  padding-top: 0.65rem !important;
}

@media (max-width: 1200px) {
  .brand-logo {
    width: min(720px, 70vw) !important;
    max-height: 205px !important;
  }
}

@media (max-width: 900px) {
  nav {
    flex-direction: column !important;
    align-items: flex-start !important;
  }
  .brand-logo {
    width: min(680px, 96vw) !important;
    max-height: 190px !important;
  }
  nav .nav-links {
    margin-left: 0 !important;
    padding-top: 0.25rem !important;
  }
}

@media (max-width: 700px) {
  .brand-logo {
    width: min(560px, 96vw) !important;
    max-height: 165px !important;
  }
}


/* Web-legible logo and bilingual footer alignment update */
html, body {
  min-height: 100%;
}
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main {
  flex: 1 0 auto;
}
.site-footer {
  flex-shrink: 0;
}
nav {
  justify-content: flex-start !important;
  align-items: flex-start !important;
  padding: 0.18rem 1rem 0.45rem 0.55rem !important;
  gap: 1.25rem !important;
}
.brand {
  flex: 0 1 auto !important;
  max-width: min(860px, 62vw) !important;
}
.brand-logo {
  width: min(860px, 62vw) !important;
  max-height: 255px !important;
  height: auto !important;
  object-fit: contain !important;
  object-position: left top !important;
  display: block !important;
}
nav .nav-links {
  margin-left: auto !important;
  padding-top: 0.7rem !important;
  align-items: center !important;
}
.mandate-note {
  background: var(--navy-deep);
  color: var(--white);
}
.mandate-note .section {
  padding-top: 0;
  padding-bottom: 0;
}
.mandate-note p {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  color: rgba(255,255,255,0.88);
}
.footer-inner {
  align-items: flex-start !important;
}
.footer-text-brand {
  min-width: 260px;
}
.footer-meta {
  line-height: 1.55;
}
@media (max-width: 1100px) {
  .brand, .brand-logo {
    width: min(760px, 96vw) !important;
    max-width: min(760px, 96vw) !important;
    max-height: 225px !important;
  }
  nav {
    flex-direction: column !important;
  }
  nav .nav-links {
    margin-left: 0 !important;
    padding-top: 0.1rem !important;
  }
}
@media (max-width: 700px) {
  nav {
    padding-left: 0.35rem !important;
    padding-right: 0.35rem !important;
  }
  .brand, .brand-logo {
    width: 98vw !important;
    max-width: 98vw !important;
    max-height: 190px !important;
  }
  .footer-inner {
    gap: 0.75rem !important;
  }
}


/* Research paper library */
.eyebrow.light {
  color: rgba(255,255,255,0.88);
}
.eyebrow.light::after {
  background: rgba(255,255,255,0.72);
}
.research-library .library-intro {
  max-width: 900px;
  margin-bottom: 1.4rem;
}
.paper-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  align-items: stretch;
}
.paper-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.45rem;
  box-shadow: 0 12px 28px rgba(7,37,58,0.06);
}
.paper-card.featured-paper {
  border-left: 5px solid var(--teal);
}
.paper-card.pending-paper {
  background: #fbfdfe;
}
.paper-meta {
  color: var(--teal);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.55rem;
}
.paper-card h2 {
  margin: 0 0 0.7rem;
  font-size: 1.35rem;
  line-height: 1.2;
}
.paper-card h2 a {
  color: var(--navy);
}
.paper-card h2 a:hover {
  color: var(--teal);
  text-decoration: none;
}
.paper-card p {
  margin: 0 0 1rem;
}
.paper-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.8rem 0 1rem;
}
.paper-tags span {
  display: inline-block;
  border: 1px solid var(--line);
  background: var(--teal-soft);
  color: var(--navy);
  border-radius: 999px;
  padding: 0.24rem 0.62rem;
  font-size: 0.84rem;
  font-weight: 650;
}
.text-link {
  font-weight: 800;
}
.paper-hero .section {
  max-width: 980px;
}
.paper-body {
  max-width: 920px;
  background: var(--white);
}
.paper-body h2 {
  margin-top: 2rem;
}
.paper-body h3 {
  margin: 0 0 0.35rem;
  color: var(--navy);
}
.paper-body p,
.paper-body li {
  font-size: 1.04rem;
}
.paper-notice {
  border-left: 5px solid var(--teal);
  background: var(--teal-soft);
  padding: 1rem 1.1rem;
  border-radius: 12px;
}
.framework-list {
  display: grid;
  gap: 0.9rem;
  margin: 1rem 0;
}
.framework-list section {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem 1.1rem;
  background: #fbfdfe;
}
.paper-footer-nav {
  margin-top: 2.2rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
}
@media (max-width: 820px) {
  .paper-grid {
    grid-template-columns: 1fr;
  }
}


.paper-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
  margin-top: 1rem;
}
.small-cta {
  padding: 0.7rem 1rem;
  font-size: 0.92rem;
}
.outline-cta {
  display: inline-block;
  border: 1px solid var(--teal);
  color: var(--navy);
  background: transparent;
  padding: 0.85rem 1.15rem;
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
}
.outline-cta:hover {
  background: var(--teal-soft);
  text-decoration: none;
}
.thesis-download-panel {
  display: flex;
  justify-content: space-between;
  gap: 1.2rem;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.1rem 1.2rem;
  margin: 1.2rem 0 1.7rem;
  background: #fbfdfe;
  box-shadow: 0 10px 24px rgba(7,37,58,0.05);
}
.thesis-download-panel h2 {
  margin: 0 0 0.35rem;
}
.thesis-download-panel p {
  margin: 0;
}
.panel-actions {
  justify-content: flex-end;
  min-width: 240px;
}
.thesis-body {
  line-height: 1.72;
}
.paper-footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}
@media (max-width: 820px) {
  .thesis-download-panel {
    flex-direction: column;
    align-items: flex-start;
  }
  .panel-actions {
    justify-content: flex-start;
    min-width: 0;
  }
}


/* Legal pages */
.legal-page {
  max-width: 900px;
  line-height: 1.72;
}

.legal-page h2 {
  margin-top: 2rem;
}

.paper-notice {
  border-left: 4px solid var(--teal);
  background: var(--teal-soft);
  padding: 1rem 1.2rem;
  border-radius: 10px;
}

.footer-links a {
  font-weight: 600;
}

/* Cookie acceptance bar */
.cookie-notice {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 1080px;
  margin: 0 auto;
  padding: 1rem 1.1rem;
  background: rgba(6, 31, 51, 0.96);
  color: var(--white);
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.28);
}

.cookie-notice a {
  color: #9ee7f5;
  text-decoration: underline;
}

.cookie-notice__text {
  font-size: 0.95rem;
  line-height: 1.5;
}

.cookie-notice__actions {
  display: flex;
  gap: 0.7rem;
  align-items: center;
  flex-shrink: 0;
}

.cookie-notice__button {
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1.1rem;
  font-weight: 800;
  color: var(--white);
  background: var(--teal);
  cursor: pointer;
  white-space: nowrap;
}

.cookie-notice__button:hover,
.cookie-notice__button:focus {
  background: #095d77;
}

.cookie-notice__button--secondary {
  color: var(--white);
  background: transparent;
  border: 1px solid rgba(255,255,255,0.46);
}

.cookie-notice__button--secondary:hover,
.cookie-notice__button--secondary:focus {
  background: rgba(255,255,255,0.12);
}

@media (max-width: 720px) {
  .cookie-notice {
    flex-direction: column;
    align-items: flex-start;
  }

  .cookie-notice__actions {
    width: 100%;
    flex-direction: column;
  }

  .cookie-notice__button {
    width: 100%;
  }
}

/* Footer transparent icon + tighter bilingual text lockup */
.footer-lockup {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 0.75rem !important;
  min-width: 280px;
}

.footer-icon {
  width: 86px !important;
  height: 86px !important;
  object-fit: contain !important;
  display: block !important;
  flex: 0 0 auto !important;
  background: transparent !important;
  border-radius: 0 !important;
}

.footer-text-group {
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
  line-height: 1.15;
}

.footer-lockup .footer-title {
  font-size: 1.12rem !important;
  line-height: 1.12 !important;
  margin: 0 !important;
}

.footer-lockup .footer-sub {
  font-size: 0.96rem !important;
  line-height: 1.16 !important;
  margin: 0 !important;
}

@media (max-width: 700px) {
  .footer-lockup {
    gap: 0.65rem !important;
    min-width: 0;
  }
  .footer-icon {
    width: 74px !important;
    height: 74px !important;
  }
}

/* Evening header logo size tweak: keep the updated logo, reduce top-left footprint */
nav {
  padding: 0.45rem 1.25rem 0.55rem 0.75rem !important;
  align-items: flex-start !important;
}
.brand {
  max-width: min(560px, 50vw) !important;
}
.brand-logo {
  width: min(560px, 50vw) !important;
  max-width: min(560px, 50vw) !important;
  max-height: 175px !important;
}
nav .nav-links {
  padding-top: 0.45rem !important;
}
@media (max-width: 1100px) {
  .brand, .brand-logo {
    width: min(520px, 94vw) !important;
    max-width: min(520px, 94vw) !important;
    max-height: 165px !important;
  }
}
@media (max-width: 700px) {
  .brand, .brand-logo {
    width: 94vw !important;
    max-width: 94vw !important;
    max-height: 145px !important;
  }
}
