/* ============================================================
   footer.css — un singur subsol pentru toate paginile AuditAI.
   Structura este cea din platforma TrainAi, adaptată la paleta
   AuditAI (alb cald, fildeș, auri #8f6319):
     1. bara de securitate — 3 pastile;
     2. rîndul de documente legale — 6 pastile (GDPR, SECURITATE,
        PRIVACY, TERMENI, COOKIES, ANPC);
     3. identitatea firmei + codul QR al platformei;
     4. linia de copyright.
   position:relative + z-index:2 țin subsolul deasupra fundalului
   fix al paginii (css/fonduri-pagini.css).
   ============================================================ */

footer,
footer.site-footer {
    position: relative;
    z-index: 2;
    margin-top: 26px;
    padding: 0 16px 22px;
    border: 0;
    background: transparent;
    color: var(--ink-soft, #6b6154);
    font-family: var(--sans, system-ui, "Segoe UI", sans-serif);
    font-size: 13px;
    letter-spacing: 0;
    line-height: 1.8;
    text-align: center;
    text-transform: none;
    container-type: inline-size;
}

footer a { color: var(--brand-dark, #6f4c12); text-decoration: none; }
footer a:hover { text-decoration: underline; }

/* ============================================================
   1. Bara de securitate (3 pastile, ca în platforma de referință)
   ============================================================ */
.foot-siguranta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    max-width: 860px;
    margin: 0 auto 12px;
}

.foot-btn-siguranta {
    display: inline-block;
    padding: 6px 14px;
    border: 1px solid rgba(143, 99, 25, .28);
    border-radius: 999px;
    background: rgba(255, 255, 255, .62);
    color: var(--brand-dark, #6f4c12);
    font-size: 12.5px;
    line-height: 1.5;
    letter-spacing: 0;
    text-decoration: none;
    text-transform: none;
    transition: background .15s ease, border-color .15s ease;
}

.foot-btn-siguranta:hover {
    border-color: rgba(143, 99, 25, .55);
    background: rgba(143, 99, 25, .10);
    text-decoration: none;
}

/* ============================================================
   2. Rîndul de documente legale (aceleași 6 pastile pe toate paginile)
   ============================================================ */
.foot-legal {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    max-width: 860px;
    margin: 0 auto 4px;
    font-size: 12.5px;
    line-height: 1.6;
}

.foot-legal a {
    display: inline-block;
    padding: 5px 13px;
    border: 1px solid rgba(143, 99, 25, .28);
    border-radius: 999px;
    background: rgba(255, 255, 255, .62);
    color: var(--brand-dark, #6f4c12);
    text-decoration: none;
    transition: background .15s ease, border-color .15s ease;
}

.foot-legal a:hover {
    border-color: rgba(143, 99, 25, .55);
    background: rgba(143, 99, 25, .10);
    text-decoration: none;
}

/* ============================================================
   3. Identitatea firmei + coloana QR.
   Tabelul stă în stînga, QR-ul fără cadran, în dreapta, cu
   înălțimea luată de la tabel (nu iese deasupra / dedesubt).
   ============================================================ */
.foot-firma {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    max-width: 1040px;
    margin: 8px auto 0;
}

.tabel-firma-footer {
    flex: 0 1 auto;
    width: auto;
    min-width: 0;
    max-width: 100%;
    margin: 0;
    border-collapse: collapse;
    table-layout: auto;
    background: transparent;
    color: inherit;
    font-size: 12px;
    line-height: 1.5;
    text-align: left;
}

.tabel-firma-footer td {
    padding: 5px 8px;
    border-bottom: 0;
    text-align: left;
    vertical-align: middle;
    overflow-wrap: anywhere;
}

/* Coloana stîngă se lărgește doar cît are nevoie textul.
   Adresa (coloana 2) stă pe un singur rînd cît timp încape. */
.tabel-firma-footer td:first-child { width: 1%; white-space: nowrap; }
.tabel-firma-footer td:last-child { white-space: nowrap; }
.tabel-firma-footer tr:first-child td:first-child { color: var(--ink, #3a3227); font-weight: 700; letter-spacing: .02em; }

/* Zona QR: fără cadran alb, fără padding, doar codul. */
.foot-firma > #qr-platforma-zona {
    position: relative;
    box-sizing: border-box;
    flex: 0 0 56px;
    align-self: stretch;
    width: 56px;
    min-height: 56px;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
}

.foot-qr .qr-platforma {
    position: absolute;
    top: 50%;
    left: 0;
    width: 56px;
    height: 56px;
    margin: 0;
    line-height: 0;
    cursor: pointer;
    transform: translateY(-50%);
}

.foot-qr .qr-platforma svg { display: block; width: 100%; height: 100%; }

.foot-copy { margin: 8px 0 0; font-size: 12.5px; opacity: .92; }

/* Containere înguste (cardurile de login/zone, coloane de 900 px): adresa
   se împarte pe două rînduri, iar QR-ul coboară sub tabel, centrat.
   Pragul e generos (1020 px) ca adresa să nu împingă niciodată tabelul
   în afara containerului. */
@container (max-width: 1020px) {
    .foot-firma { flex-direction: column; align-items: center; gap: 8px; }
    .tabel-firma-footer { width: 100%; max-width: 100%; }
    .tabel-firma-footer td { text-align: center; }
    .tabel-firma-footer td:last-child { white-space: normal; }
    .tabel-firma-footer td:first-child { width: auto; }
    .foot-firma > #qr-platforma-zona { flex: 0 0 72px; align-self: auto; width: 72px; height: 72px; min-height: 0; margin: 0 auto; }
    .foot-qr .qr-platforma { position: static; width: 72px; height: 72px; margin: 0 auto; transform: none; }
}

@media (max-width: 760px) {
    .foot-firma { flex-direction: column; gap: 8px; }
    .tabel-firma-footer { flex: 0 0 auto; width: 100%; }
    .tabel-firma-footer td { display: block; width: auto; padding: 1px 6px; text-align: center; white-space: normal; }
    .foot-firma > #qr-platforma-zona { flex: 0 0 88px; width: 88px; height: 88px; margin: 2px auto 0; }
    .foot-qr .qr-platforma { position: static; width: 88px; height: 88px; margin: 0 auto; transform: none; }
}

