/*
Theme Name: TSWS 2026
Theme URI: https://thesunworkshop.com
Author: The Sun Workshop
Description: Thème bloc léger pour The Sun Workshop, optimisé pour WooCommerce et les parcours professionnels.
Version: 0.6.3
Requires at least: 6.6
Requires PHP: 8.1
Text Domain: tsws-2026
*/

@font-face {
  font-family: "Manrope";
  src: url("assets/fonts/Manrope-Variable.woff") format("woff");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --tsws-blue: #3c64aa;
  --tsws-blue-dark: #163b75;
  --tsws-yellow: #f0b414;
  --tsws-yellow-soft: #f3d38b;
  --tsws-ink: #08111b;
  --tsws-muted: #5d6b7e;
  --tsws-cloud: #f3f7fc;
  --tsws-white: #fff;
  --tsws-line: #dce6f2;
  --tsws-radius: 28px;
  --tsws-shadow: 0 24px 70px rgba(16, 32, 57, .12);
}

html { scroll-behavior: smooth; }
body {
  color: var(--tsws-ink);
  background: var(--tsws-white);
  font-family: "Manrope", Arial, sans-serif;
  text-rendering: optimizeLegibility;
}
a { text-underline-offset: .18em; }
img { max-width: 100%; height: auto; }
.wp-site-blocks { overflow: clip; }
.tsws-shell { width: min(1200px, calc(100% - 40px)); margin-inline: auto; }

.tsws-topbar {
  background: var(--tsws-blue-dark);
  color: #fff;
  font-size: .82rem;
  letter-spacing: .02em;
  padding: .62rem 0;
}
.tsws-topbar a { color: #fff; text-decoration: none; }
.tsws-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255,255,255,.94);
  border-bottom: 1px solid rgba(220,230,242,.85);
  backdrop-filter: blur(18px);
}
.tsws-header-inner { min-height: 82px; }
.tsws-header .wp-block-site-logo img { width: 178px; height: auto; }
.tsws-header .wp-block-navigation { font-weight: 700; font-size: .92rem; }
.tsws-header .wp-block-navigation-item__content { text-decoration: none; }
.tsws-header .wp-block-navigation-item__content:hover { color: var(--tsws-blue); }

.wp-block-button__link,
.tsws-button {
  border-radius: 999px !important;
  font-weight: 800;
  padding: .95rem 1.35rem;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.wp-block-button__link:hover,
.tsws-button:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(22,59,117,.18); }
.tsws-button-secondary .wp-block-button__link {
  background: #fff !important;
  color: var(--tsws-blue-dark) !important;
  border: 1px solid var(--tsws-line);
}

.tsws-hero-wrap { padding: 28px 0 44px; }
.tsws-hero {
  position: relative;
  min-height: 640px;
  border-radius: 36px;
  overflow: hidden;
  background:
    radial-gradient(circle at 88% 8%, rgba(245,182,23,.34), transparent 32%),
    linear-gradient(135deg, #f8fbff 0%, #e9f1fb 55%, #d4e2f5 100%);
  box-shadow: var(--tsws-shadow);
}
.tsws-hero::before {
  content: "";
  position: absolute;
  width: 430px;
  height: 430px;
  right: -90px;
  bottom: -170px;
  border: 78px solid rgba(65,104,177,.13);
  border-radius: 50%;
}
.tsws-hero-copy { position: relative; z-index: 3; padding: clamp(46px, 7vw, 92px); }
.tsws-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  color: var(--tsws-blue-dark);
  font-weight: 800;
  font-size: .78rem;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.tsws-eyebrow::before { content: ""; width: 28px; height: 4px; border-radius: 9px; background: var(--tsws-yellow); }
.tsws-hero h1 { max-width: 760px; margin: .7rem 0 1.1rem; font-size: clamp(2.65rem, 6vw, 5.8rem); line-height: .96; letter-spacing: -.055em; }
.tsws-hero-copy > p:not(.tsws-eyebrow) { max-width: 650px; color: var(--tsws-muted); font-size: clamp(1rem, 1.7vw, 1.25rem); line-height: 1.7; }
.tsws-hero-visual { position: relative; min-height: 520px; align-self: stretch; }
.tsws-product-orbit { position: absolute; inset: 0; }
.tsws-product-orbit img { position: absolute; object-fit: contain; filter: drop-shadow(0 28px 32px rgba(16,32,57,.22)); }
.tsws-product-orbit .product-main { width: 58%; right: 8%; bottom: 2%; z-index: 2; }
.tsws-product-orbit .product-side { width: 43%; left: -2%; top: 8%; z-index: 1; }
.tsws-product-badge {
  position: absolute;
  right: 8%;
  top: 9%;
  z-index: 4;
  width: 118px;
  height: 118px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--tsws-yellow);
  color: var(--tsws-ink);
  text-align: center;
  font-weight: 800;
  transform: rotate(8deg);
  box-shadow: 0 18px 36px rgba(161,109,0,.2);
}

.tsws-proof-strip { margin-top: -22px !important; position: relative; z-index: 4; }
.tsws-proof-strip > .wp-block-group__inner-container,
.tsws-proof-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #fff;
  border: 1px solid var(--tsws-line);
  border-radius: 24px;
  box-shadow: 0 16px 38px rgba(16,32,57,.09);
}
.tsws-proof-item { padding: 24px; text-align: center; font-weight: 800; border-right: 1px solid var(--tsws-line); }
.tsws-proof-item:last-child { border-right: 0; }
.tsws-proof-item small { display: block; color: var(--tsws-muted); font-weight: 600; margin-top: .35rem; }

.tsws-section { padding: clamp(68px, 9vw, 120px) 0; }
.tsws-section-soft { background: var(--tsws-cloud); }
.tsws-section-dark { background: var(--tsws-blue-dark); color: #fff; }
.tsws-section-head { max-width: 760px; margin-bottom: 42px; }
.tsws-section-head h2 { margin: .55rem 0 .8rem; font-size: clamp(2rem, 4vw, 4rem); line-height: 1.06; letter-spacing: -.04em; }
.tsws-section-head p { color: var(--tsws-muted); font-size: 1.08rem; line-height: 1.7; }
.tsws-section-dark .tsws-section-head p { color: #c9d7ea; }

.tsws-card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.tsws-card {
  position: relative;
  min-height: 310px;
  padding: 30px;
  border: 1px solid var(--tsws-line);
  border-radius: var(--tsws-radius);
  background: #fff;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.tsws-card:hover { transform: translateY(-6px); box-shadow: var(--tsws-shadow); border-color: transparent; }
.tsws-card-number { color: var(--tsws-blue); font-weight: 800; font-size: .78rem; letter-spacing: .12em; }
.tsws-card h3 { font-size: 1.5rem; margin: 2rem 0 .6rem; }
.tsws-card p { color: var(--tsws-muted); line-height: 1.65; }
.tsws-card a { color: var(--tsws-blue-dark); font-weight: 800; text-decoration: none; }
.tsws-card-featured { background: var(--tsws-yellow); border-color: var(--tsws-yellow); }
.tsws-card-featured p { color: #3b3527; }

.tsws-network-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(40px, 7vw, 78px);
  border-radius: 36px;
  background: linear-gradient(135deg, #173f7b 0%, #4168b1 100%);
}
.tsws-network-panel::after { content: ""; position: absolute; width: 420px; height: 420px; right: -150px; top: -170px; border: 78px solid rgba(255,255,255,.08); border-radius: 50%; }
.tsws-network-panel h2 { max-width: 760px; font-size: clamp(2.1rem, 4.2vw, 4.4rem); line-height: 1.05; letter-spacing: -.04em; }
.tsws-network-panel p { color: #d9e4f3; max-width: 700px; line-height: 1.7; }
.tsws-benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 42px; }
.tsws-benefit { padding: 22px; border-radius: 20px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.16); }
.tsws-benefit strong { display: block; color: var(--tsws-yellow); margin-bottom: .45rem; }

.tsws-category-grid { display: grid; grid-template-columns: 1.2fr .9fr .9fr; gap: 20px; }
.tsws-category {
  position: relative;
  min-height: 420px;
  overflow: hidden;
  padding: 30px;
  border-radius: 30px;
  background: #edf3fb;
}
.tsws-category h3 { position: relative; z-index: 2; margin: 0; font-size: 1.5rem; }
.tsws-category p { position: relative; z-index: 2; color: var(--tsws-muted); }
.tsws-category img { position: absolute; max-height: 72%; max-width: 88%; object-fit: contain; right: -4%; bottom: -4%; filter: drop-shadow(0 24px 30px rgba(16,32,57,.18)); }
.tsws-category:first-child { background: var(--tsws-blue-dark); color: #fff; }
.tsws-category:first-child p { color: #cfdbed; }

.tsws-products .products { display: grid !important; grid-template-columns: repeat(4, 1fr) !important; gap: 22px; margin: 0 !important; }
.tsws-products .product { width: auto !important; margin: 0 !important; padding: 16px 16px 22px !important; border: 1px solid var(--tsws-line); border-radius: 24px; background: #fff; }
.tsws-products .product img { border-radius: 16px; aspect-ratio: 1 / 1; object-fit: contain; background: #f6f8fb; }
.tsws-products .woocommerce-loop-product__title { font-size: 1rem !important; min-height: 3em; color: var(--tsws-ink); }
.tsws-products .price { color: var(--tsws-blue-dark) !important; font-weight: 800 !important; }
.tsws-price-tier { display: block; margin-top: .3rem; color: var(--tsws-muted); font-size: .72rem; font-weight: 700; }
.tsws-products .button { border-radius: 999px !important; background: var(--tsws-blue) !important; color: #fff !important; }

.tsws-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: steps; }
.tsws-step { padding: 28px; border-top: 4px solid var(--tsws-yellow); background: #fff; border-radius: 0 0 22px 22px; box-shadow: 0 14px 35px rgba(16,32,57,.07); }
.tsws-step::before { counter-increment: steps; content: "0" counter(steps); color: var(--tsws-blue); font-weight: 800; font-size: .82rem; }
.tsws-step h3 { margin: 1.3rem 0 .55rem; }
.tsws-step p { color: var(--tsws-muted); line-height: 1.6; }

.tsws-realisation {
  min-height: 560px;
  display: flex;
  align-items: flex-end;
  border-radius: 34px;
  overflow: hidden;
  background: linear-gradient(180deg, transparent 20%, rgba(8,25,50,.9) 100%), url('/wp-content/uploads/2026/02/Montage-panneaux-solaire.webp') center/cover;
  color: #fff;
}
.tsws-realisation-copy { max-width: 720px; padding: clamp(32px, 7vw, 72px); }
.tsws-realisation-copy h2 { font-size: clamp(2rem, 4vw, 4rem); margin: 0 0 1rem; }
.tsws-realisation-copy p { color: #dce6f4; }

.tsws-logo-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; align-items: center; }
.tsws-logo-row figure { height: 92px; display: grid; place-items: center; margin: 0; padding: 22px; border: 1px solid var(--tsws-line); border-radius: 20px; background: #fff; }
.tsws-logo-row img { max-height: 48px; width: auto; object-fit: contain; filter: grayscale(1); opacity: .7; transition: filter .2s, opacity .2s; }
.tsws-logo-row figure:hover img { filter: none; opacity: 1; }

.tsws-cta {
  padding: clamp(42px, 7vw, 78px);
  border-radius: 36px;
  background: var(--tsws-yellow);
  color: var(--tsws-ink);
}
.tsws-cta h2 { margin: 0; font-size: clamp(2rem, 4vw, 4.2rem); line-height: 1.05; }

.tsws-footer { background: #0d2343; color: #fff; padding: 70px 0 24px; }
.tsws-footer a { color: #d9e4f3; text-decoration: none; }
.tsws-footer h3 { color: #fff; font-size: 1rem; }
.tsws-footer p { color: #b8c8dd; }
.tsws-footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 38px; }
.tsws-footer-logo { width: 190px; filter: brightness(0) invert(1); }
.tsws-footer-bottom { margin-top: 52px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.13); color: #9fb0c7; font-size: .84rem; }

.tsws-page-hero { padding: 74px 0 56px; background: var(--tsws-cloud); }
.tsws-page-hero h1 { font-size: clamp(2.5rem, 5vw, 5rem); letter-spacing: -.05em; }
.entry-content > *:not(.alignfull) { width: min(1200px, calc(100% - 40px)); margin-inline: auto; }
.entry-content > .alignwide { width: min(1200px, calc(100% - 40px)); }

.tsws-form { display: grid; gap: 16px; max-width: 780px; }
.tsws-form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.tsws-field label { display: block; font-weight: 800; margin-bottom: .45rem; }
.tsws-field input,
.tsws-field select,
.tsws-field textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #cbd8e8;
  border-radius: 14px;
  padding: .9rem 1rem;
  font: inherit;
  background: #fff;
}
.tsws-field input:focus,
.tsws-field select:focus,
.tsws-field textarea:focus { outline: 3px solid rgba(65,104,177,.22); border-color: var(--tsws-blue); }
.tsws-notice { padding: 16px 18px; border-radius: 14px; background: #eef7ef; color: #24552a; border: 1px solid #b9d9bd; }
.tsws-notice-error { background: #fff0f0; color: #7b2424; border-color: #efbcbc; }

@media (max-width: 960px) {
  .tsws-hero { min-height: auto; }
  .tsws-hero .wp-block-columns { flex-wrap: wrap !important; }
  .tsws-hero .wp-block-column { flex-basis: 100% !important; }
  .tsws-hero-visual { min-height: 430px; }
  .tsws-card-grid, .tsws-benefits, .tsws-category-grid { grid-template-columns: 1fr 1fr; }
  .tsws-category:first-child { grid-column: 1 / -1; }
  .tsws-products .products { grid-template-columns: repeat(2, 1fr) !important; }
  .tsws-steps { grid-template-columns: 1fr 1fr; }
  .tsws-logo-row { grid-template-columns: repeat(3, 1fr); }
  .tsws-footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 680px) {
  .tsws-shell { width: min(100% - 24px, 1200px); }
  .tsws-topbar { text-align: center; }
  .tsws-header-inner { min-height: 70px; }
  .tsws-header .wp-block-site-logo img { width: 145px; }
  .tsws-hero-wrap { padding-top: 12px; }
  .tsws-hero { border-radius: 24px; }
  .tsws-hero-copy { padding: 36px 24px 10px; }
  .tsws-hero h1 { font-size: clamp(2.55rem, 14vw, 4.2rem); }
  .tsws-hero-visual { min-height: 330px; }
  .tsws-product-orbit .product-main { width: 60%; right: 4%; }
  .tsws-product-orbit .product-side { width: 48%; left: -5%; top: 4%; }
  .tsws-product-badge { width: 88px; height: 88px; font-size: .76rem; }
  .tsws-proof-strip > .wp-block-group__inner-container, .tsws-proof-inner { grid-template-columns: 1fr 1fr; }
  .tsws-proof-item:nth-child(2) { border-right: 0; }
  .tsws-proof-item:nth-child(-n+2) { border-bottom: 1px solid var(--tsws-line); }
  .tsws-card-grid, .tsws-benefits, .tsws-category-grid, .tsws-steps, .tsws-logo-row, .tsws-footer-grid, .tsws-form-grid { grid-template-columns: 1fr; }
  .tsws-category:first-child { grid-column: auto; }
  .tsws-category { min-height: 350px; }
  .tsws-products .products { grid-template-columns: 1fr !important; }
  .tsws-realisation { min-height: 480px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
