/* Portails client / apprenant et pages publiques — porté depuis prototype/portail-*.html */
html { scroll-padding-top: 84px; }

/* Barre de l'espace client */
.portal-bar { position: sticky; top: 0; z-index: 1030; background: color-mix(in srgb, var(--gt-surface) 90%, transparent); backdrop-filter: saturate(180%) blur(10px); border-bottom: 1px solid var(--gt-border); }
.portal-bar .navbar { min-height: 68px; }
.portal-bar .brand { display: flex; align-items: center; gap: 10px; color: var(--gt-text); }
.portal-bar .brand img { width: 36px; height: 36px; }
.portal-bar .brand .name { font-weight: 700; line-height: 1; }
.portal-bar .brand .name span { color: var(--gt-blue-2); }
.portal-bar .brand .sub { font-size: .62rem; color: var(--gt-muted); letter-spacing: .08em; text-transform: uppercase; }
.portal-bar .nav-link { color: var(--gt-text-2); font-size: .84rem; font-weight: 500; padding: 8px 12px !important; border-radius: 8px; display: flex; align-items: center; gap: 6px; }
.portal-bar .nav-link:hover, .portal-bar .nav-link.active { color: var(--gt-blue-2); background: rgba(25, 118, 210, .08); }
.portal-bar .btn-icon { width: 40px; height: 40px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; color: var(--gt-text-2); border: 1px solid transparent; background: transparent; }
.portal-bar .btn-icon:hover { background: var(--gt-surface-2); border-color: var(--gt-border); }
.portal-main { max-width: 1240px; margin: 0 auto; padding: 24px 16px 48px; }
@media (min-width: 992px) { .portal-main { padding: 28px 24px 56px; } }

/* Barre de l'espace apprenant */
.portal-nav { background: linear-gradient(90deg, #0a1d3d, #0d2a5c); position: sticky; top: 0; z-index: 1030; }
.portal-nav .navbar-brand { display: flex; align-items: center; gap: 10px; color: #fff; }
.portal-nav .navbar-brand img { width: 34px; height: 34px; }
.portal-nav .navbar-brand .n { font-weight: 700; font-size: 1.05rem; line-height: 1; }
.portal-nav .navbar-brand .n span { color: var(--gt-cyan); }
.portal-nav .navbar-brand .s { font-size: .55rem; letter-spacing: .3em; color: #8fa3c4; }
.portal-nav .nav-link { color: #c7d2e5; font-size: .85rem; font-weight: 500; border-radius: 8px; padding: 8px 12px !important; display: flex; align-items: center; gap: 6px; }
.portal-nav .nav-link:hover, .portal-nav .nav-link.active { color: #fff; background: rgba(255,255,255,.08); }
.portal-nav .navbar-toggler { border-color: rgba(255,255,255,.25); color: #fff; }
.portal-nav .icon-btn { width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; color: #c7d2e5; border: 1px solid rgba(255,255,255,.15); background: transparent; }
.portal-nav .icon-btn:hover { color: #fff; background: rgba(255,255,255,.08); }
.portal-content { padding: 24px 0 40px; }
.next-class { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15); border-radius: 14px; padding: 16px; }
.mod-step { display: flex; align-items: center; gap: 10px; font-size: .8rem; padding: 6px 0; }
.mod-step .dot { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: .65rem; font-weight: 600; flex-shrink: 0; border: 2px solid var(--gt-border); color: var(--gt-muted); }
.mod-step.done .dot { background: var(--gt-success); border-color: var(--gt-success); color: #fff; }
.mod-step.current .dot { border-color: var(--gt-blue-2); color: var(--gt-blue-2); }
.mod-step.current { font-weight: 600; }
.date-chip { width: 52px; text-align: center; border-radius: 12px; border: 1px solid var(--gt-border); padding: 6px 0; flex-shrink: 0; background: var(--gt-surface); }
.date-chip .d { font-size: 1.1rem; font-weight: 700; line-height: 1; }
.date-chip .m { font-size: .62rem; text-transform: uppercase; letter-spacing: .08em; color: var(--gt-muted); }
.date-chip.today { border-color: var(--gt-blue-2); background: rgba(25,118,210,.08); }
.balance-card { background: linear-gradient(135deg, #0a1d3d, #0d47a1); color: #fff; border: 0; }
.balance-card .text-white-50 { color: rgba(255,255,255,.7) !important; }

/* Déclaration de paiement */
.pay-method { border: 2px solid var(--gt-border); border-radius: 12px; padding: 12px 8px; text-align: center; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: .76rem; font-weight: 500; height: 100%; color: var(--gt-text); }
.pay-method .logo { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .75rem; }
.btn-check:checked + .pay-method { border-color: var(--gt-blue-2); background: rgba(25, 118, 210, .06); }
.btn-check:focus-visible + .pay-method { box-shadow: 0 0 0 .2rem rgba(25, 118, 210, .25); }
.pay-om { background: #ff7900; color: #fff; }
.pay-mtn { background: #ffcb05; color: #0a1d3d; }
.pay-summary { background: var(--gt-surface-2); border: 1px solid var(--gt-border); }

/* Pages publiques */
.pub-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 0; }
.pub-brand { display: flex; align-items: center; gap: 10px; color: #fff; }
.pub-brand:hover { color: #fff; }
.pub-brand img { width: 36px; height: 36px; }
.pub-brand .n { font-weight: 700; font-size: 1.1rem; line-height: 1; }
.pub-brand .n span { color: var(--gt-cyan); }
.pub-brand .s { font-size: .55rem; letter-spacing: .32em; color: #8fa3c4; }
.pub-hero { background: radial-gradient(900px 420px at 85% 0%, rgba(0,194,255,.32), transparent 60%), linear-gradient(135deg, #0a1d3d 0%, #0d47a1 100%); color: #fff; padding-bottom: 96px; }
.pub-hero.pub-hero-lg { padding-bottom: 120px; }
.pub-hero h1 { color: #fff; font-size: clamp(1.6rem, 4.5vw, 2.6rem); font-weight: 700; line-height: 1.15; }
.pub-hero h1 .accent { color: var(--gt-cyan); }
.pub-hero .lead { color: rgba(255,255,255,.78); font-size: 1rem; }
.hero-stat { color: #fff; }
.hero-stat .v { font-size: 1.4rem; font-weight: 700; }
.hero-stat .l { font-size: .75rem; color: rgba(255,255,255,.7); }
.hero-pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 14px; border-radius: 999px; background: rgba(255,255,255,.12); color: #fff; font-size: .78rem; font-weight: 500; }
.btn-ghost { color: #fff; border: 1px solid rgba(255,255,255,.25); background: rgba(255,255,255,.06); }
.btn-ghost:hover { color: #fff; background: rgba(255,255,255,.14); }
.pub-main { margin-top: -64px; }
.pub-footer { color: var(--gt-muted); font-size: .78rem; padding: 32px 0; }
.sec-num { width: 30px; height: 30px; border-radius: 50%; background: var(--gt-blue); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 600; font-size: .85rem; flex-shrink: 0; }
.choice { cursor: pointer; border: 1px solid var(--gt-border); border-radius: 12px; padding: 12px 14px; display: flex; gap: 12px; align-items: center; height: 100%; color: var(--gt-text); transition: border-color .15s, background .15s; }
.choice:hover { border-color: #b9c8de; }
.btn-check:checked + .choice { border-color: var(--gt-blue-2); background: rgba(25,118,210,.07); box-shadow: 0 0 0 1px var(--gt-blue-2); }
.btn-check:disabled + .choice { opacity: .5; cursor: not-allowed; }
.btn-check:focus-visible + .choice { outline: 2px solid var(--gt-blue-2); outline-offset: 2px; }
.choice .kpi-icon { width: 42px; height: 42px; }
.summary { position: sticky; top: 20px; }
.summary .total { font-size: 1.5rem; font-weight: 700; letter-spacing: -.02em; }
.confirm-icon { width: 84px; height: 84px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 2.6rem; }
.hp-field { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }

/* Vérification de certificat */
.verify-card { margin-top: -90px; }
.code-input { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .06em; text-transform: uppercase; font-size: 1rem !important; }
.result-icon { width: 72px; height: 72px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 2.2rem; }
.cert-num { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .03em; }

/* Ticket : fil de discussion */
.msg { border: 1px solid var(--gt-border); border-radius: 12px; padding: 12px 14px; }
.msg.mine { background: rgba(25,118,210,.06); border-color: rgba(25,118,210,.25); }
.msg .meta { font-size: .72rem; color: var(--gt-muted); margin-bottom: 4px; }
.msg .body { white-space: pre-line; font-size: .85rem; }

@media print {
  .portal-bar, .portal-nav, .pub-nav { display: none !important; }
}
