/*
Theme Name: Saiep Paris v2
Theme URI: https://www.saiep-paris.fr
Description: Child theme v2 — Shanghai government-inspired visual identity (white background, government blue actions, serif headings).
Author: lidesign
Version: 2.0.0
Template: saiep-paris
Text Domain: saiep-paris-v2
*/

:root {
  --saiep-gold:        #1a57a8;
  --saiep-gold-deep:   #123f7a;
  --saiep-gold-soft:   #e8f1fb;
  --saiep-navy:        #11294d;
  --saiep-navy-soft:   #2b3a4f;
  --saiep-ink:         #1f2937;
  --saiep-muted:       #4b5563;
  --saiep-bg:          #ffffff;
  --saiep-surface:     #ffffff;
  --saiep-border:      #e5e7eb;
  --saiep-accent-red:  #c8102e;
  --saiep-max:         92rem;
  --saiep-radius:      0.4rem;
  --saiep-shadow:      0 6px 16px rgba(17,24,39,0.08);
  --saiep-font-sans:   "Noto Sans SC", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Heiti SC", sans-serif;
  --saiep-font-serif:  "Source Han Serif SC", "Noto Serif SC", "Songti SC", serif;
  --saiep-font-en:     "DIN", "Helvetica Neue", Arial, sans-serif;
}

html, body {
  background: var(--saiep-bg);
  color: var(--saiep-ink);
  font-family: var(--saiep-font-sans);
  font-size: 16px;
  line-height: 1.7;
}
a { color: var(--saiep-gold-deep); text-decoration: none; transition: color .2s ease, opacity .2s ease; }
a:hover { color: var(--saiep-gold); }
h1, h2, h3, h4, h5, h6 {
  font-family: var(--saiep-font-serif);
  color: var(--saiep-navy);
  font-weight: 700;
  letter-spacing: .02em;
  line-height: 1.35;
}
h1 { font-size: 1.85rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }

#headerwrap { background: transparent; }
#headerpad { padding: 0; }
#header.xtc-wrapper { max-width: var(--saiep-max); margin: 0 auto; }

.topbar-v2 {
  position: relative;
  z-index: 30;
  display: flex;
  align-items: center;
  height: 84px;
  min-height: 84px;
  padding: 0 20px;
  background: #ffffff;
  border-bottom: 1px solid var(--saiep-border);
  transition: background .35s ease, box-shadow .35s ease;
}
.topbar-v2.stuck {
  position: fixed; inset: 0 0 auto 0;
  background: #fff; backdrop-filter: none;
  border-bottom: 0.5px solid var(--saiep-border);
  box-shadow: 0 4px 16px rgba(0,0,0,.06);
}
.topbar-v2 .brand-group {
  display: flex; align-items: center; gap: 18px; flex: 0 0 auto;
}
.topbar-v2 .brand img { display: block; height: 43px; width: auto; }
.topbar-v2 .brand-sub img { height: 32px; }
.topbar-v2 .topnav {
  margin-left: auto;
  height: 84px;
  display: flex;
  align-items: center;
}
.topbar-v2 .v2menu {
  display: flex;
  align-items: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.topbar-v2 .v2menu > li { position: relative; }
.topbar-v2 .v2menu > li > a {
  display: flex;
  align-items: center;
  height: 84px;
  padding: 0 13px;
  color: #1f2937;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  transition: background .2s, color .2s;
}
.topbar-v2 .v2menu > li:hover > a,
.topbar-v2 .v2menu > li.current-menu-item > a,
.topbar-v2 .v2menu > li.current-menu-ancestor > a {
  color: #fff;
  background: var(--saiep-gold-deep);
}
.topbar-v2 .v2menu > li > ul {
  position: absolute;
  top: 84px;
  left: 0;
  z-index: 60;
  display: none;
  min-width: 190px;
  margin: 0;
  padding: 6px 0;
  list-style: none;
  background: #fff;
  border: 1px solid var(--saiep-border);
  border-radius: 0 0 6px 6px;
  box-shadow: 0 12px 24px rgba(0,0,0,.12);
}
.topbar-v2 .v2menu > li:hover > ul,
.topbar-v2 .v2menu > li:focus-within > ul { display: block; }
.topbar-v2 .v2menu > li > ul > li > a {
  display: block;
  padding: 9px 16px;
  color: #333;
  font-size: 14px;
  white-space: nowrap;
}
.topbar-v2 .v2menu > li > ul > li > a:hover { background: #f6f3ee; color: var(--saiep-gold-deep); }

.topbar-v2 .lang-switch { display: inline-flex; gap: 6px; margin-left: 18px; align-items: center; }
.topbar-v2 .lang-switch img { width: 22px; height: 16px; border-radius: 2px; opacity: .85; }
.topbar-v2 .lang-switch img:hover { opacity: 1; }
.topbar-v2 .mobilebtn { display: none; margin-left: auto; }
.topbar-v2 .mobilebtn select {
  max-width: 180px; height: 34px; border: 1px solid #d8cfc0; border-radius: 4px;
  background: #fff; color: #333; font-size: 14px; padding: 0 8px;
}

.catItemView, .featurednews_text, .categorynewsmain, .categorynewsmore {
  background: var(--saiep-surface);
  border: 1px solid var(--saiep-border);
  border-radius: var(--saiep-radius);
  box-shadow: var(--saiep-shadow);
  padding: 1.1rem 1.25rem;
  transition: transform .2s ease, box-shadow .2s ease;
}
.catItemView:hover { transform: translateY(-3px); box-shadow: 0 12px 24px rgba(17,19,24,.16); }
.catItemView .itemTitle a { color: var(--saiep-navy); font-family: var(--saiep-font-serif); }
.catItemView .itemTitle a:hover { color: var(--saiep-gold-deep); }
.catItemIntroText { color: var(--saiep-muted); font-size: .95rem; }

.single-post .entry-title, .itemTitle { font-family: var(--saiep-font-serif); color: var(--saiep-navy); }
.itemHeader .itemTitle { font-size: 1.5rem; }

table.category { width: 100%; border-collapse: collapse; margin: 0 0 24px; }
tr.cat-list-row0 td, tr.cat-list-row1 td {
  border-bottom: 1px solid var(--saiep-border);
  padding: 18px 6px; font-family: var(--saiep-font-sans); font-size: 20px;
  line-height: 1.45; color: var(--saiep-navy);
}
tr.cat-list-row0 td a, tr.cat-list-row1 td a { color: inherit; text-decoration: none; }
tr.cat-list-row0 td a:hover, tr.cat-list-row1 td a:hover { color: var(--saiep-gold-deep); }
@media (max-width: 767px) {
  tr.cat-list-row0 td, tr.cat-list-row1 td { font-size: 16px; padding: 12px 4px; }
}

#footerwrap { background: var(--saiep-navy-soft); color: rgba(255,255,255,.9); }
#footerwrap a { color: rgba(255,255,255,.9); }
#footerwrap a:hover { color: var(--saiep-gold); }
.site-footer-top-v2 {
  padding: .9rem 1rem; background: rgba(52,56,63,.92);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-site-links { max-width: var(--saiep-max); margin: 0 auto; font-size: .9rem; }
.footer-site-links-list {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-around;
  gap: .6rem 1.6rem; margin: 0; padding: 0; list-style: none;
}
.footer-site-links a { color: rgba(255,255,255,.96); transition: color .2s, transform .2s; }
.footer-site-links a:hover { color: var(--saiep-gold); transform: translateY(-1px); }
.site-footer-main-v2 {
  max-width: var(--saiep-max); margin: 0 auto; padding: 1.1rem 0 1rem;
  display: flex; align-items: stretch; justify-content: flex-start; gap: 8px;
}
.site-footer-info-v2 {
  flex: 1.45 1 0; display: flex; justify-content: center; align-items: flex-start;
  padding: .85rem 1rem; background: var(--saiep-navy-soft); border-radius: var(--saiep-radius);
}
.site-footer-badges-v2 {
  flex: 1.05 1 0; display: grid; grid-template-columns: repeat(4, minmax(0,1fr));
  gap: .9rem; padding: .85rem; border-radius: var(--saiep-radius);
  background: var(--saiep-navy-soft);
}
.footer-badge { display: flex; align-items: center; justify-content: center; width: 100%;
  min-height: 3.7rem; padding: .45rem .55rem; border-radius: .35rem; background: #fff;
  box-shadow: 0 8px 18px rgba(17,19,24,.14); }
.footer-badge img { max-width: 100%; max-height: 3rem; object-fit: contain; }
.site-footer-bottom-v2 {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: .75rem; padding: .95rem 1rem 1.1rem; font-size: .83rem;
  color: rgba(255,255,255,.82); text-align: center; background: var(--saiep-navy-soft);
}

@media (max-width: 980px) {
  .topbar-v2 { height: 68px; min-height: 68px; }
  .topbar-v2 .topnav { height: 68px; }
  .topbar-v2 .v2menu > li > a { height: 68px; font-size: 14px; padding: 0 8px; }
  .topbar-v2 .brand img { height: 34px; }
}
@media (max-width: 760px) {
  .topbar-v2 .topnav { display: none; }
  .topbar-v2 .mobilebtn { display: block; }
  .site-footer-main-v2 { flex-direction: column; }
  .site-footer-badges-v2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 980px) {
  .imgframe { box-sizing: border-box; max-width: 100%; }
}
CSS
echo "style.css written"
/* ============================================================
   Optimization pass: contrast, image ratio, main landmark
   ============================================================ */
.fnewsitemintro,
.featurednews_text,
.featurednews_text p,
.featurednews_text div,
.categorynewsmore,
.categorynewsmain { color: #2b2b2b !important; }

img.imgframe { height: auto; max-width: 100%; }

#saiep-main { display: block; }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ============================================================
   Layout fixes (1920 desktop, cards, sidebar)
   ============================================================ */
.categorynewsmain .fnewsitem,
.categorynewsmore .featurednews_text { box-sizing: border-box; overflow: hidden; }

.categorynewsmain .fnewsitem img,
.categorynewsmore .featurednews_text img {
  display: block !important;
  width: 100% !important;
  height: auto !important;
  float: none !important;
}

@media (min-width: 1200px) {
  #right2 { position: sticky; top: 100px; align-self: flex-start; }
}

/* Announcement list in homepage sidebar */
#right2 .v2annlist { margin: 0; padding: 0; list-style: none; }
#right2 .v2annlist li { padding: 8px 0; border-bottom: 1px dashed #e2dbcf; }
#right2 .v2annlist li:last-child { border-bottom: 0; }
#right2 .v2annlist li a {
  display: block; color: #3a3a3a; font-size: 14px; line-height: 1.45;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
#right2 .v2annlist li a:hover { color: var(--saiep-gold-deep); }

/* Mobile header override (parent .mobilebtn is a 18px hamburger box) */
.topbar-v2 .mobilebtn {
  display: none;
  width: auto; height: auto; padding: 0; margin-left: auto;
  background: none !important; overflow: visible; float: none;
}
.topbar-v2 .mobilebtn select.v2mobilemenu {
  width: auto; max-width: 52vw; height: 36px;
  background: #fff !important; border: 1px solid #d8cfc0 !important;
  border-radius: 4px; padding: 0 8px; font-size: 14px; color: #333;
}
@media (max-width: 760px) {
  .topbar-v2 .mobilebtn { display: block; }
  .topbar-v2 .brand img { height: 34px; }
  .topbar-v2 .lang-switch { margin-left: 10px; }
}

/* Responsive header: switch to select below 1400, prevent overflow */
.topbar-v2 { gap: 10px; }
.topbar-v2 .brand-group { min-width: 0; flex-shrink: 1; }
.topbar-v2 .brand img { max-width: 100%; }
.topbar-v2 .topnav { min-width: 0; }
.topbar-v2 .v2menu { min-width: 0; }
@media (min-width: 1400px) {
  .topbar-v2 .v2menu > li > a { font-size: 15px; padding: 0 10px; }
}
@media (max-width: 1399px) {
  .topbar-v2 .topnav { display: none; }
  .topbar-v2 .mobilebtn { display: block; }
}
@media (max-width: 480px) {
  .topbar-v2 { padding: 0 10px; }
  .topbar-v2 .brand img { height: 28px; }
  .topbar-v2 .mobilebtn select.v2mobilemenu { max-width: 44vw; }
  .topbar-v2 .lang-switch { margin-left: 8px; gap: 4px; }
  .topbar-v2 .lang-switch img { width: 18px; height: 13px; }
}

/* ============================================================
   Government blue skin (white background + blue actions)
   ============================================================ */
body { background: #ffffff; }

/* Buttons */
button,
input[type="submit"],
input[type="button"],
.btn,
.button,
.wp-block-search__button,
.search-form input[type="submit"],
#searchform input[type="submit"] {
  background: #1a57a8 !important;
  color: #ffffff !important;
  border: 1px solid #1a57a8 !important;
  border-radius: 3px !important;
  padding: 8px 18px !important;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
  box-shadow: none;
  transition: background .2s ease, border-color .2s ease;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
.btn:hover,
.button:hover,
.wp-block-search__button:hover {
  background: #123f7a !important;
  border-color: #123f7a !important;
  color: #fff !important;
}

/* Form fields */
input[type="search"],
input[type="text"],
input[type="email"],
input[type="url"],
input[type="tel"],
textarea,
select {
  border: 1px solid #d7dde5;
  border-radius: 3px;
  padding: 8px 10px;
  background: #fff;
  color: #1f2937;
}
input[type="search"]:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="url"]:focus,
input[type="tel"]:focus,
textarea:focus,
select:focus {
  border-color: #1a57a8;
  outline: 2px solid #e8f1fb;
  outline-offset: 0;
}

/* Pagination */
.pagination .page-numbers,
.nav-links .page-numbers,
.page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  margin: 0 3px;
  border: 1px solid #d7dde5;
  border-radius: 3px;
  background: #fff;
  color: #1f2937;
  text-decoration: none;
}
.page-numbers.current {
  background: #1a57a8;
  border-color: #1a57a8;
  color: #fff;
}
.page-numbers:hover {
  border-color: #1a57a8;
  color: #1a57a8;
}

/* Section titles with government-style blue rule */
.module .moduletitle {
  border-bottom: 2px solid #1a57a8;
  padding-bottom: 8px;
}
.module .moduletitle .first_word {
  color: #11294d;
  font-weight: 700;
}

/* News list hover */
.fnewsitemintro a:hover,
.featurednews_text a:hover,
.v2annlist li a:hover { color: #1a57a8; }

/* Sidebar cards keep white with thin border */
.bnewsitem { background: #fff; }

/* Links in content */
.entry-content a,
.itemFullText a,
.itemIntroText a { color: #1a57a8; text-decoration: none; border-bottom: 1px solid #cfe0f5; }
.entry-content a:hover,
.itemFullText a:hover,
.itemIntroText a:hover { color: #123f7a; border-bottom-color: #123f7a; }

/* Prominent government-blue actions */
.frontpage .v2menu > li:first-child > a,
.home .v2menu > li:first-child > a {
  background: #1a57a8;
  color: #fff;
}
.footer-email-btn {
  background: #1a57a8 !important;
  border: 1px solid #1a57a8 !important;
  color: #fff !important;
  border-radius: 3px !important;
}
.footer-email-btn:hover {
  background: #123f7a !important;
  border-color: #123f7a !important;
  color: #fff !important;
}
.pagination .page-numbers.current,
.page-numbers.current {
  background: #1a57a8 !important;
  border-color: #1a57a8 !important;
  color: #fff !important;
}

/* Ensure the footer contact renders as a real blue button */
#footerwrap .footer-email-btn,
.footer-email-btn {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 112px;
  height: 36px;
  padding: 0 16px !important;
  margin-top: 10px;
  font-size: 14px;
  line-height: 1;
  text-decoration: none !important;
}

/* Force homepage card images visible (parent theme hides .featurednews_text img on desktop) */
#user1 .categorynewsmain img {
  display: block !important;
  visibility: visible !important;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  float: none !important;
}
#user1 .categorynewsmore .featurednews_text img,
#user2 .categorynewsmore .featurednews_text img {
  display: block !important;
  visibility: visible !important;
  width: 100% !important;
  height: 180px !important;
  object-fit: cover;
  float: none !important;
  margin: 6px 0 8px;
}
