/* ProfiGarden – Odstúpenie od zmluvy – Frontend */

:root {
    --pgn-wr-primary:   #659900;
    --pgn-wr-primary-h: #4E7501;
    --pgn-wr-text:      #111827;
    --pgn-wr-muted:     #6b7280;
    --pgn-wr-border:    #e5e7eb;
    --pgn-wr-bg-soft:   #f9fafb;
    --pgn-wr-bg-muted:  #f3f4f6;
    --pgn-wr-font:      "Hanken Grotesk", sans-serif;
}

/* ── Floating Button ─────────────────────────────────── */
#pgn-wr-toggle {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 9998;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 10px 16px;
    background: var(--pgn-wr-primary);
    color: #fff;
    border: none;
    border-radius: 0;
    font-family: var(--pgn-wr-font);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow: 0 2px 12px rgba(101,153,0,.30);
    transition: background .25s;
    white-space: nowrap;
}
#pgn-wr-toggle:hover  { background: var(--pgn-wr-primary-h); }
#pgn-wr-toggle svg    { flex-shrink: 0; stroke: #fff; }

/* ── Overlay ─────────────────────────────────────────── */
#pgn-wr-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
#pgn-wr-overlay[hidden] { display: none !important; }

/* ── Modal ───────────────────────────────────────────── */
#pgn-wr-modal {
    background: #fff;
    border: 1px solid var(--pgn-wr-border);
    border-radius: 0;
    padding: 36px 32px 32px;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 8px 32px rgba(0,0,0,.12);
    animation: pgn-wr-in .2s ease-out;
    font-family: var(--pgn-wr-font);
    color: var(--pgn-wr-text);
    box-sizing: border-box;
}
#pgn-wr-modal *,
#pgn-wr-modal *::before,
#pgn-wr-modal *::after { box-sizing: border-box; }

@keyframes pgn-wr-in {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Close ───────────────────────────────────────────── */
#pgn-wr-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    color: var(--pgn-wr-muted);
    padding: 4px 6px;
    font-family: var(--pgn-wr-font);
    transition: color .15s;
}
#pgn-wr-close:hover { color: var(--pgn-wr-text); }

/* ── Header text ─────────────────────────────────────── */
.pgn-wr-eyebrow {
    font-size: 11px;
    font-weight: 700;
    color: var(--pgn-wr-primary);
    letter-spacing: 0.07em;
    text-transform: uppercase;
    margin: 0 0 8px;
}

#pgn-wr-modal-title {
    font-size: clamp(20px, 4vw, 28px);
    font-weight: 700;
    color: var(--pgn-wr-text);
    line-height: 1.2;
    margin: 0 0 10px;
}

.pgn-wr-subtitle {
    font-size: 13px;
    color: var(--pgn-wr-muted);
    line-height: 1.6;
    margin: 0 0 24px;
}

/* ── Fields ──────────────────────────────────────────── */
.pgn-wr-field {
    margin-bottom: 16px;
}
.pgn-wr-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--pgn-wr-text);
    margin-bottom: 5px;
}
.pgn-wr-field label span[aria-hidden] { color: var(--pgn-wr-primary); }
.pgn-wr-optional {
    font-size: 12px;
    font-weight: 400;
    color: var(--pgn-wr-muted);
}

.pgn-wr-field input[type="text"],
.pgn-wr-field input[type="email"],
.pgn-wr-field textarea {
    width: 100%;
    padding: 10px 12px;
    background: var(--pgn-wr-bg-soft);
    border: 1px solid var(--pgn-wr-border);
    border-radius: 0;
    font-family: var(--pgn-wr-font);
    font-size: 14px;
    color: var(--pgn-wr-text);
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}
.pgn-wr-field input::placeholder,
.pgn-wr-field textarea::placeholder { color: var(--pgn-wr-muted); }

.pgn-wr-field input:focus,
.pgn-wr-field textarea:focus {
    border-color: var(--pgn-wr-primary);
    box-shadow: 0 0 0 3px rgba(101,153,0,.12);
    background: #fff;
}
.pgn-wr-field textarea { resize: vertical; min-height: 80px; }

/* Checkbox */
.pgn-wr-checkbox-label {
    display: flex !important;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-weight: 400 !important;
}
.pgn-wr-checkbox-label input[type="checkbox"] {
    margin-top: 2px;
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--pgn-wr-primary);
    border-radius: 0;
}
.pgn-wr-checkbox-label span {
    font-size: 13px;
    color: var(--pgn-wr-text);
    line-height: 1.55;
}

/* ── Errors ──────────────────────────────────────────── */
.pgn-wr-errors {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-left: 3px solid #dc2626;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 13px;
    color: #dc2626;
}
.pgn-wr-errors[hidden] { display: none; }
.pgn-wr-errors ul { margin: 0; padding-left: 16px; }
.pgn-wr-errors li { margin-bottom: 3px; }

/* ── Submit ──────────────────────────────────────────── */
#pgn-wr-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 13px 28px;
    background: var(--pgn-wr-primary);
    color: #fff;
    border: none;
    border-radius: 0;
    font-family: var(--pgn-wr-font);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .25s;
}
#pgn-wr-submit:hover    { background: var(--pgn-wr-primary-h); }
#pgn-wr-submit:disabled { opacity: .55; cursor: not-allowed; }

.pgn-wr-btn-spinner {
    width: 15px;
    height: 15px;
    border: 2px solid rgba(255,255,255,.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: pgn-wr-spin .7s linear infinite;
    flex-shrink: 0;
}
.pgn-wr-btn-spinner[hidden] { display: none; }
@keyframes pgn-wr-spin { to { transform: rotate(360deg); } }

.pgn-wr-required-note {
    margin: 10px 0 0;
    font-size: 12px;
    color: var(--pgn-wr-muted);
    text-align: center;
}

/* ── Success ─────────────────────────────────────────── */
#pgn-wr-success {
    text-align: center;
    padding: 24px 0;
}
#pgn-wr-success[hidden] { display: none; }

.pgn-wr-success-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border: 2px solid var(--pgn-wr-primary);
    margin: 0 auto 16px;
    font-size: 22px;
    color: var(--pgn-wr-primary);
}

#pgn-wr-success-msg {
    font-size: 16px;
    font-weight: 500;
    color: var(--pgn-wr-text);
    line-height: 1.5;
}

/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 480px) {
    #pgn-wr-modal { padding: 24px 18px 20px; }
    #pgn-wr-toggle span { display: none; }
    #pgn-wr-toggle { padding: 11px 12px; }
}
