/* Formularz konkursowy Trust Your Wings – ciemnobrązowa karta wg projektu */
.tyw-form {
    --tyw-brown: #493930;
    --tyw-turquoise: #47C2CC;
    --tyw-white: #ffffff;

    font-family: 'Inter', "Helvetica Neue", Helvetica, Arial, sans-serif;
    background: var(--tyw-brown);
    color: var(--tyw-white);
    max-width: 720px;
    margin: 0 auto;
    padding: 40px 36px 44px;
    border-radius: 24px;
    box-sizing: border-box;
}
.tyw-form *, .tyw-form *::before, .tyw-form *::after { box-sizing: border-box; }

.tyw-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--tyw-white);
    margin: 0 0 8px;
    font-family: 'Inter';
}
.tyw-intro {
    font-size: 18px;
    line-height: 1.4em;
    margin: 0 0 26px;
    color: rgba(255, 255, 255, .85);
}

.tyw-field { margin-bottom: 18px; }

.tyw-label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--tyw-white);
}

.tyw-form input[type="text"],
.tyw-form input[type="email"],
.tyw-form input[type="tel"] {
    width: 100%;
    padding: 13px 20px;
    font-size: 15px;
    font-family: inherit;
    border: 1px solid transparent;
    border-radius: 8px;
    background: var(--tyw-white);
    color: #333;
}
.tyw-form input:focus { outline: none; border-color: var(--tyw-turquoise); }
.tyw-form ::placeholder { color: #a5a5a5; }

/* Pole uploadu – kreskowana ramka */
.tyw-upload {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    padding: 28px 20px;
    border: 1.5px dashed rgba(255, 255, 255, .6);
    border-radius: 16px;
    cursor: pointer;
    transition: border-color .2s ease, background .2s ease;
}
.tyw-upload:hover,
.tyw-upload.tyw-dragover {
    border-color: var(--tyw-turquoise);
    background: rgba(255, 255, 255, .05);
}
.tyw-upload input[type="file"] {
    position: absolute;
    width: 1px; height: 1px;
    opacity: 0;
    overflow: hidden;
}
.tyw-upload-icon { color: var(--tyw-white); display: inline-flex; }
.tyw-upload-label { font-size: 16px; font-weight: 700; }
.tyw-upload-hint {
    font-size: 14px;
    line-height: 1.4em;
    color: #F4FBFB;
    margin-top: 10px;
}
.tyw-file-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--tyw-turquoise);
    word-break: break-all;
}

/* Zgody */
.tyw-consents { margin: 18px 0 6px; }
.tyw-consent {
    display: grid;
    grid-template-columns: 16px 1fr;
    gap: 10px;
    font-size: 11px;
    line-height: 1.55;
    color: rgba(255, 255, 255, .75);
    margin-bottom: 10px;
    cursor: pointer;
}
.tyw-consent input[type="checkbox"] {
    width: 16px; height: 16px;
    margin-top: 1px;
    accent-color: var(--tyw-turquoise);
}
.tyw-consent a { color: var(--tyw-white); text-decoration: underline; }
.tyw-consent a:hover { text-decoration: none; }

/* Honeypot */
.tyw-hp { position: absolute; left: -9999px; top: -9999px; }

/* Błąd */
.tyw-error {
    background: rgba(255, 255, 255, .1);
    border: 1px solid #e07070;
    color: #ffd7d7;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 13px;
    margin: 14px 0;
}
.tyw-form [hidden] { display: none !important; }

/* Przycisk */
.tyw-submit {
    display: inline-block;
    background: var(--tyw-white);
    color: var(--tyw-brown);
    border: none;
    border-radius: 999px;
    padding: 14px 36px;
    font-size: 15px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    margin-top: 12px;
    transition: background .3s ease, color .3s ease, transform .2s ease;
}
.tyw-submit:hover { background: #47C2CC; color: #fff; }
.tyw-submit:disabled { opacity: .7; cursor: wait; }

.tyw-processing {
    font-size: 12px;
    color: rgba(255, 255, 255, .75);
    margin: 10px 0 0;
}

/* Awaryjny sukces (normalnie następuje przekierowanie na stronę THX) */
.tyw-success { text-align: center; padding: 20px 0; }
.tyw-success h2 { color: var(--tyw-white); font-size: 24px; margin: 0 0 12px; }
.tyw-success p { font-size: 15px; line-height: 1.6; margin: 8px 0; }
.tyw-success strong { font-size: 24px; letter-spacing: .06em; color: var(--tyw-turquoise); }

/* Formularz zamknięty */
.tyw-closed { text-align: center; padding: 36px 24px; font-size: 15px; }

@media (max-width: 640px) {
    .tyw-form { padding: 30px 22px 34px; border-radius: 0; }
    .tyw-title { text-align:center; }
    .tyw-intro {
        text-align: center;
        font-size: 16px;
    }
}

/* --- dopisek pod polem uploadu --- */
.tyw-upload-note {
    font-size: 12px;
    text-align: center;
    line-height: 1.5em;
    color: var(--tyw-white);
    margin: 16px 0 6px;
}

/* --- zgoda: okrągły checkbox jak w projekcie --- */
.tyw-consent {
    grid-template-columns: 26px 1fr;
    align-items: start;
    font-size: 14px;
    color: var(--tyw-white);
}
.tyw-consent input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 24px;
    height: 24px;
    margin-top: 0;
    border: 1.5px solid var(--tyw-white);
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    display: inline-grid;
    place-content: center;
    transition: background .2s ease, border-color .2s ease;
}
.tyw-consent input[type="checkbox"]::after {
    content: "";
    width: 12px;
    height: 12px;
    transform: scale(0);
    transition: transform .15s ease;
    background: var(--tyw-white);
    clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
}
.tyw-consent input[type="checkbox"]:checked {
    background: var(--tyw-turquoise);
    border-color: var(--tyw-turquoise);
}
.tyw-consent input[type="checkbox"]:checked::after { transform: scale(1); }

/* --- informacja RODO (bez checkboxa) --- */
.tyw-rodo-info {
    font-size: 8px;
    line-height: 1.2em;
    color: #F4FBFB;
    margin: 4px 0 0;
    padding-left: 36px;
}
@media (max-width: 640px) {
    .tyw-rodo-info { padding-left: 0; }
}
