/* ==================================================
   LIGA IV LEMKARI SULUT 2026 - GLOBAL THEME
================================================== */

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    max-width: 100%;
    overflow-x: hidden;
    font-family: Arial, Helvetica, sans-serif;
    background: #f3f4f6;
    color: #1f2937;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ==================================================
   PAGE WRAPPER
================================================== */

.page-wrapper {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    background: #fff8dc;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.12);
}

.content-wrapper {
    padding: 22px;
    text-align: center;
}

/* ==================================================
   PAGE TITLE
================================================== */

.page-title {
    background: linear-gradient(135deg, #991b1b, #dc2626, #facc15);
    color: #ffffff;
    text-align: center;
    padding: 24px 16px;
    border-radius: 18px;
    margin: 0 auto 22px;
    box-shadow: 0 8px 22px rgba(185, 28, 28, 0.22);
}

.page-title h1 {
    margin: 0;
    font-size: 28px;
    font-weight: 900;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.45);
}

.page-title p {
    margin: 8px 0 0;
    font-size: 15px;
    color: #fff7cc;
    font-weight: 800;
}

/* ==================================================
   BUTTON GROUPS
================================================== */

.participant-buttons,
.registration-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin: 0 auto 24px;
    text-align: center;
}

.participant-buttons a,
.registration-buttons a {
    display: inline-block;
    padding: 12px 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 900;
    background: #ffffff;
    color: #b91c1c;
    border: 2px solid #b91c1c;
    box-shadow: 0 6px 14px rgba(185, 28, 28, 0.18);
    transition: all 0.25s ease;
}

.participant-buttons a.active,
.registration-buttons a.active {
    background: linear-gradient(135deg, #991b1b, #dc2626);
    color: #ffff00;
    border-color: #991b1b;
}

.participant-buttons a:hover,
.registration-buttons a:hover {
    background: linear-gradient(135deg, #7f1d1d, #b91c1c);
    color: #ffff00;
    border-color: #7f1d1d;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(185, 28, 28, 0.28);
}

/* ==================================================
   CARDS
================================================== */

.info-card,
.notice-box,
.payment-card,
.form-card,
.table-card,
.detail-card {
    width: 100%;
    background: #ffffff;
    border: 1px solid #f1d98a;
    border-radius: 18px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
}

.info-card {
    max-width: 850px;
    margin: 0 auto 22px;
    border-left: 7px solid #dc2626;
    padding: 18px 20px;
    text-align: center;
}

.info-card h2,
.table-title,
.payment-card h2 {
    margin: 0 0 16px;
    color: #b91c1c;
    font-size: 22px;
    font-weight: 900;
    text-align: center;
}

.info-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    max-width: 620px;
    margin: 0 auto;
}

.info-item {
    background: #fffbea;
    border: 1px solid #f1d98a;
    border-radius: 12px;
    padding: 12px 14px;
    line-height: 1.5;
}

.info-label {
    display: block;
    color: #7f1d1d;
    font-weight: 900;
    margin-bottom: 3px;
}

.info-value {
    color: #111827;
    font-weight: 900;
}

.notice-box {
    max-width: 850px;
    margin: 0 auto 22px;
    border-left: 7px solid #dc2626;
    padding: 18px 20px;
    text-align: center;
    color: #1e40af;
    font-size: 17px;
    line-height: 1.6;
}

.not-registered {
    max-width: 850px;
    margin: 0 auto 22px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-left: 7px solid #f97316;
    border-radius: 16px;
    padding: 18px 20px;
    text-align: center;
    color: #7c2d12;
    font-weight: 800;
    line-height: 1.7;
}

.not-registered a {
    color: #b91c1c;
    font-weight: 900;
    text-decoration: underline;
}

/* ==================================================
   TABLES
================================================== */

.table-card {
    padding: 18px;
    margin: 0 auto 22px;
    overflow: hidden;
}

.table-scroll {
    width: 100%;
    overflow-x: auto;
}

.data-table,
.summary-table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
}

.data-table {
    min-width: 760px;
    font-size: 14px;
}

.data-table th {
    background: linear-gradient(135deg, #991b1b, #dc2626);
    color: #ffff00;
    padding: 12px 10px;
    border: 1px solid #7f1d1d;
    text-align: center;
    white-space: nowrap;
}

.data-table td {
    padding: 10px 9px;
    border: 1px solid #d1d5db;
    vertical-align: middle;
    color: #111827;
}

.data-table tr:nth-child(even) td {
    background: #fffbea;
}

.data-table tr:hover td {
    background: #fee2e2;
}

.summary-table {
    max-width: 720px;
    margin: 0 auto;
    font-size: 15px;
}

.summary-table td {
    padding: 12px 14px;
    border: 1px solid #f1d98a;
}

.summary-table .label {
    text-align: right;
    font-weight: 800;
    color: #374151;
    background: #fffbea;
}

.summary-table .amount {
    text-align: right;
    font-weight: 900;
    color: #111827;
    white-space: nowrap;
}

.summary-table .total-row td {
    background: linear-gradient(135deg, #991b1b, #dc2626);
    color: #ffff00;
    font-size: 17px;
    font-weight: 900;
}

/* ==================================================
   ROW COLORS
================================================== */

.row-pria td {
    background: #e0f2fe;
}

.row-wanita td {
    background: #ffe4ec;
}

.row-pria:hover td {
    background: #bae6fd;
}

.row-wanita:hover td {
    background: #fecdd3;
}

/* ==================================================
   LINKS, STATUS, TEXT HELPERS
================================================== */

.athlete-link {
    color: #b91c1c;
    font-weight: 900;
    text-decoration: none;
}

.athlete-link:hover {
    color: #7f1d1d;
    text-decoration: underline;
}

.status-ya {
    display: inline-block;
    min-width: 34px;
    padding: 4px 8px;
    border-radius: 999px;
    background: #bbf7d0;
    color: #14532d;
    font-weight: 900;
    text-align: center;
}

.status-tidak {
    color: #9ca3af;
    font-weight: 700;
}

.money {
    white-space: nowrap;
    font-weight: 900;
    color: #111827;
}

.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.empty-result {
    text-align: center;
    padding: 20px;
    color: #b91c1c;
    font-weight: 900;
    background: #fffbea;
}

/* ==================================================
   BACK / ACTION / PAYMENT BUTTONS
================================================== */

.back-button {
    text-align: center;
    margin-top: 22px;
}

.back-button a,
.pay-button,
.submit-btn,
.reset-btn {
    display: inline-block;
    border: none;
    border-radius: 999px;
    padding: 12px 22px;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.25s ease;
}

.back-button a,
.pay-button,
.submit-btn {
    background: linear-gradient(135deg, #991b1b, #dc2626);
    color: #ffff00;
    box-shadow: 0 6px 14px rgba(185, 28, 28, 0.24);
}

.back-button a:hover,
.pay-button:hover,
.submit-btn:hover {
    background: linear-gradient(135deg, #7f1d1d, #b91c1c);
    color: #ffffff;
    transform: translateY(-2px);
}

.reset-btn {
    background: #e5e7eb;
    color: #374151;
}

.reset-btn:hover {
    background: #d1d5db;
    transform: translateY(-2px);
}

/* ==================================================
   FORMS
================================================== */

.form-card {
    max-width: 820px;
    margin: 0 auto 22px;
    overflow: hidden;
}

.form-section {
    padding: 22px;
    border-bottom: 1px solid #f3e7b4;
    background: #ffffff;
}

.form-section:nth-child(even) {
    background: #fffbea;
}

.form-section:last-child {
    border-bottom: none;
}

.section-heading {
    margin: 0 0 18px;
    color: #b91c1c;
    font-size: 20px;
    font-weight: 900;
    text-align: center;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.form-group {
    margin-bottom: 18px;
    text-align: left;
}

.form-group:last-child {
    margin-bottom: 0;
}

label {
    display: block;
    font-size: 15px;
    font-weight: 800;
    color: #374151;
    margin-bottom: 7px;
}

.required {
    color: #dc2626;
    font-weight: 900;
}

.optional,
.help-text {
    color: #6b7280;
    font-weight: 700;
}

.help-text {
    display: block;
    font-size: 13px;
    line-height: 1.5;
    margin-top: 4px;
    margin-bottom: 8px;
}

input[type=text], input[type=email], input[type=date], input[type=password], select, textarea {
    width: 100%;
    padding: 12px 13px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    font-size: 15px;
    font-family: Arial, Helvetica, sans-serif;
    outline: none;
    background: #ffffff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input[type=text]:focus, input[type=email]:focus, input[type=date]:focus, input[type=password]:focus, select:focus, textarea:focus {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

textarea {
    min-height: 110px;
    resize: vertical;
}

.radio-group {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.radio-option {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-weight: 700;
    color: #374151;
}

.form-actions {
    text-align: center;
    padding: 24px 22px;
    background: #ffffff;
}

.input-with-unit {
    display: flex;
    align-items: stretch;
}

.input-with-unit input {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.unit-label {
    display: inline-flex;
    align-items: center;
    padding: 0 13px;
    border: 1px solid #d1d5db;
    border-left: none;
    border-radius: 0 10px 10px 0;
    background: #f9fafb;
    font-size: 15px;
    font-weight: 900;
    color: #374151;
}

.festival-not-allowed {
    display: none;
    background: #fee2e2;
    border: 1px solid #fecaca;
    border-left: 7px solid #dc2626;
    border-radius: 14px;
    padding: 16px 18px;
    text-align: center;
    color: #7f1d1d;
    font-weight: 900;
    line-height: 1.6;
}

.participation-box {
    text-align: left;
    background: #ffffff;
    border: 1px solid #f1d98a;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 14px;
}

.participation-box:last-child {
    margin-bottom: 0;
}

.participation-title {
    text-align: left;
    font-weight: 900;
    color: #374151;
    margin-bottom: 8px;
    line-height: 1.5;
}

.participation-box .radio-group {
    justify-content: flex-start;
    text-align: left;
}

/* ==================================================
   PAYMENT
================================================== */

.payment-card {
    max-width: 850px;
    margin: 0 auto 22px;
    padding: 22px;
    text-align: center;
    line-height: 1.7;
}

/* ==================================================
   RESPONSIVE
================================================== */

@media screen and (max-width: 768px) {
    .page-wrapper {
        max-width: 100%;
        box-shadow: none;
    }

    .content-wrapper {
        padding: 14px;
    }

    .page-title {
        padding: 20px 14px;
        border-radius: 14px;
    }

    .page-title h1 {
        font-size: 23px;
        line-height: 1.3;
    }

    .participant-buttons,
    .registration-buttons {
        gap: 10px;
    }

    .participant-buttons a,
    .registration-buttons a {
        width: 100%;
        max-width: 290px;
        text-align: center;
    }

    .info-card,
    .notice-box,
    .not-registered,
    .payment-card {
        padding: 16px 14px;
    }

    .info-row,
    .form-row {
        grid-template-columns: 1fr;
    }

    .table-card {
        padding: 12px;
        border-radius: 14px;
    }

    .data-table {
        font-size: 13px;
    }

    .summary-table {
        font-size: 14px;
    }

    .summary-table .label,
    .summary-table .amount {
        display: block;
        width: 100%;
        text-align: center;
    }

    .form-section {
        padding: 18px 15px;
    }

    .section-heading {
        font-size: 18px;
    }

    .radio-group {
        flex-direction: column;
        gap: 10px;
    }

    .submit-btn,
    .reset-btn {
        width: 100%;
        max-width: 260px;
        margin: 6px auto;
    }
    
        .content-wrapper {
        text-align: center !important;
    }

    .page-title {
        text-align: center !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .page-title h1,
    .page-title p {
        text-align: center !important;
    }

    .back-button {
        text-align: center !important;
        width: 100%;
        margin-left: auto;
        margin-right: auto;
    }

    .back-button a {
        display: inline-block;
    }
}

/* ==================================================
   FINAL FORM ALIGNMENT OVERRIDE
   Khusus form pendaftaran: isi pilihan Festival/Turnamen rata kiri
================================================== */

.form-card {
    text-align: left !important;
}

.form-card .form-section,
.form-card .form-group,
.form-card .participation-box,
.form-card .participation-title,
.form-card .participation-box label,
.form-card .participation-box .radio-group,
.form-card .participation-box .radio-option {
    text-align: left !important;
}

.form-card .participation-box .radio-group {
    justify-content: flex-start !important;
    align-items: flex-start !important;
}

.form-card .participation-box .radio-option {
    display: inline-flex !important;
    justify-content: flex-start !important;
    align-items: center !important;
    width: auto !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.form-card .section-heading,
.form-card .notice-box,
.form-card .form-actions {
    text-align: center !important;
}

@media screen and (max-width: 768px) {
    .form-card,
    .form-card .form-section,
    .form-card .form-group,
    .form-card .participation-box,
    .form-card .participation-title,
    .form-card .participation-box label,
    .form-card .participation-box .radio-group,
    .form-card .participation-box .radio-option {
        text-align: left !important;
    }

    .form-card .participation-box .radio-group {
        justify-content: flex-start !important;
        align-items: flex-start !important;
    }

    .form-card .participation-box .radio-option {
        width: auto !important;
        max-width: none !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .form-card .section-heading,
    .form-card .notice-box,
    .form-card .form-actions {
        text-align: center !important;
    }
}
