/* ============================================================
   D-A-Packs Cookie Consent — Styles
   Pure CSS, no framework dependency (works alongside Tailwind)
   ============================================================ */

/* --- Banner (bottom of screen, first visit) --- */
#dap-cc-banner {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 2147483600;
    background: #ffffff;
    color: #1a1a1a;
    border-top: 4px solid #003399;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.18);
    padding: 18px 16px 18px;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 14px;
    line-height: 1.55;
    animation: dap-cc-slide-up 0.35s cubic-bezier(.22, .82, .36, 1);
}
@keyframes dap-cc-slide-up {
    from { transform: translateY(100%); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}
#dap-cc-banner .dap-cc-inner {
    max-width: 1200px; margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 22px;
    align-items: center;
}
#dap-cc-banner .dap-cc-text h3 {
    margin: 0 0 6px 0;
    font-size: 16px;
    font-weight: 800;
    color: #003399;
    letter-spacing: -0.01em;
}
#dap-cc-banner .dap-cc-text p {
    margin: 0;
    color: #475569;
}
#dap-cc-banner .dap-cc-text a {
    color: #003399;
    text-decoration: underline;
    font-weight: 600;
}
#dap-cc-banner .dap-cc-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}
@media (max-width: 820px) {
    #dap-cc-banner .dap-cc-inner {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    #dap-cc-banner .dap-cc-actions {
        flex-wrap: wrap;
    }
    #dap-cc-banner .dap-cc-actions .dap-cc-btn { flex: 1 0 auto; }
}

/* --- Buttons --- */
.dap-cc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 18px;
    border-radius: 10px;
    border: 2px solid transparent;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
    white-space: nowrap;
    line-height: 1;
}
.dap-cc-btn:focus-visible {
    outline: 3px solid rgba(255, 204, 0, 0.55);
    outline-offset: 2px;
}
.dap-cc-btn-primary {
    background: #FFCC00;
    color: #003399;
    box-shadow: 0 4px 0 #d4aa00;
}
.dap-cc-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 0 #d4aa00;
}
.dap-cc-btn-secondary {
    background: #ffffff;
    color: #003399;
    border-color: #cbd5e1;
}
.dap-cc-btn-secondary:hover {
    background: #f1f5f9;
    border-color: #003399;
}

/* --- Settings modal --- */
#dap-cc-modal {
    position: fixed; inset: 0;
    z-index: 2147483647;
    font-family: 'Segoe UI', Arial, sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: dap-cc-fade-in 0.25s ease;
}
@keyframes dap-cc-fade-in { from { opacity: 0; } to { opacity: 1; } }
#dap-cc-modal .dap-cc-modal-backdrop {
    position: absolute; inset: 0;
    background: rgba(15, 23, 42, 0.66);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}
#dap-cc-modal .dap-cc-modal-card {
    position: relative;
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.45);
    max-width: 640px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: dap-cc-pop 0.3s cubic-bezier(.22, .82, .36, 1);
}
@keyframes dap-cc-pop {
    from { transform: scale(0.95); opacity: 0; }
    to   { transform: scale(1);    opacity: 1; }
}
#dap-cc-modal header {
    padding: 18px 22px;
    background: linear-gradient(135deg, #003399 0%, #1e5cb3 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
#dap-cc-modal header h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.01em;
}
#dap-cc-modal .dap-cc-close {
    width: 32px; height: 32px;
    border: none; background: rgba(255, 255, 255, 0.18);
    color: #fff; font-size: 22px; font-weight: 700;
    border-radius: 8px; cursor: pointer; line-height: 1;
}
#dap-cc-modal .dap-cc-close:hover { background: rgba(255, 255, 255, 0.32); }

#dap-cc-modal .dap-cc-body {
    padding: 22px;
    overflow-y: auto;
    flex: 1 1 auto;
}
#dap-cc-modal .dap-cc-body > p {
    margin: 0 0 16px;
    color: #475569;
    font-size: 14px;
}
#dap-cc-modal .dap-cc-cat {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 12px;
}
#dap-cc-modal .dap-cc-cat-head {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}
#dap-cc-modal .dap-cc-cat-title {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    flex: 1;
}
#dap-cc-modal .dap-cc-cat-title em {
    font-style: normal;
    font-weight: 600;
    color: #10b981;
    font-size: 12px;
    margin-left: 4px;
}
#dap-cc-modal .dap-cc-cat p {
    margin: 8px 0 0 56px;
    font-size: 13px;
    color: #64748b;
    line-height: 1.5;
}
#dap-cc-modal footer {
    padding: 16px 22px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    flex-wrap: wrap;
}
@media (max-width: 560px) {
    #dap-cc-modal footer { justify-content: stretch; }
    #dap-cc-modal footer .dap-cc-btn { flex: 1 0 100%; }
    #dap-cc-modal .dap-cc-cat p { margin-left: 0; margin-top: 10px; }
}

/* --- Toggle switch --- */
.dap-cc-toggle {
    position: relative;
    display: inline-block;
    width: 44px; height: 24px;
    flex-shrink: 0;
}
.dap-cc-toggle input {
    opacity: 0;
    width: 100%; height: 100%;
    margin: 0; position: absolute; cursor: pointer; z-index: 2;
}
.dap-cc-toggle-track {
    position: absolute; inset: 0;
    background: #cbd5e1;
    border-radius: 999px;
    transition: background 0.2s ease;
}
.dap-cc-toggle-track::after {
    content: '';
    position: absolute;
    top: 3px; left: 3px;
    width: 18px; height: 18px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease;
}
.dap-cc-toggle input:checked + .dap-cc-toggle-track {
    background: #003399;
}
.dap-cc-toggle input:checked + .dap-cc-toggle-track::after {
    transform: translateX(20px);
}
.dap-cc-toggle-locked .dap-cc-toggle-track {
    background: #10b981 !important;
    opacity: 0.6;
}
.dap-cc-toggle-locked input { cursor: not-allowed; }

/* --- Floating reopen button --- */
#dap-cc-floater {
    position: fixed;
    left: 16px;
    bottom: 16px;
    z-index: 2147483500;
    width: 44px; height: 44px;
    border: none;
    border-radius: 50%;
    background: #003399;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(0, 51, 153, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    opacity: 0.78;
}
#dap-cc-floater:hover {
    opacity: 1;
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(0, 51, 153, 0.5);
}
#dap-cc-floater:focus-visible {
    outline: 3px solid #FFCC00;
    outline-offset: 2px;
}
#dap-cc-floater svg { display: block; }

/* --- Google Maps consent placeholder --- */
.dap-cc-map-placeholder {
    width: 100%;
    max-width: 520px;
    height: 320px;
    border-radius: 12px;
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    border: 2px dashed #94a3b8;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 22px;
    text-align: center;
    color: #334155;
    font-family: 'Segoe UI', Arial, sans-serif;
}
@media (min-width: 640px) {
    .dap-cc-map-placeholder { height: 420px; }
}
.dap-cc-map-placeholder .dap-cc-map-icon {
    width: 48px; height: 48px;
    background: #003399;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 12px;
}
.dap-cc-map-placeholder h4 {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 800;
    color: #003399;
}
.dap-cc-map-placeholder p {
    margin: 0 0 14px;
    font-size: 13px;
    line-height: 1.5;
    max-width: 380px;
}
.dap-cc-map-placeholder .dap-cc-map-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}
