﻿:root {
    --bg: #f7f7fb;
    --card: #ffffff;
    --ink: #222;
    --muted: #666;
    --brand: #005ea5;
    --accent: #0b7;
    --error: #b00020;
    /*--border: #e5e7eb;*/
    --border: #2d83d3;
}

html, body {
    height: 100%;
}

body {
    margin: 0;
    font: 16px/1.5 system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif;
    color: var(--ink);
    background: var(--bg);
    border-color: darkblue
}

.referenceNumber {
    font-weight: bold;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: clamp(12px,3vw,24px);
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,.06);
}

header {
    padding: 20px 20px 0;
    display: flex;
    align-items: center
}

    header h1 {
        font-size: clamp(20px,4vw,28px);
        margin-left: auto;
    }

    header p {
        margin: 0;
        color: var(--muted);
    }

form {
    padding: 4px 20px 20px;
}

fieldset {
    border: 0;
    padding: 0;
    margin: 22px 0;
}

legend {
    font-weight: 600;
    margin-bottom: 12px;
}

.grid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(12,1fr);
}

.col-12 {
    grid-column: span 12;
}

.col-6 {
    grid-column: span 6;
}

.col-4 {
    grid-column: span 4;
}

.col-3 {
    grid-column: span 3;
}

.col-8 {
    grid-column: span 8;
}

.col-9 {
    grid-column: span 9;
}

@media (max-width:720px) {
    .col-6, .col-4, .col-3, .col-8, .col-9 {
        grid-column: span 12;
    }
}

label {
    display: block;
    font-size: 0.9rem;
    margin: 4px 0;
}

input, select, textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

textarea {
    min-height: 90px;
}

.radio-group, .check-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.help {
    font-size: 0.85rem;
    color: var(--muted);
}

.section-note {
    background: #f0fbf4;
    border: 1px solid #d3f1df;
    padding: 10px;
    border-radius: 8px;
}

.text-error {
    color: red;
    border-color: #b00020;
}

.actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 16px;
}

button {
    appearance: none;
    border: 0;
    border-radius: 10px;
    padding: 10px 16px;
    font-weight: 600;
    cursor: pointer;
}

.navbutton-error {
    background-color: red;
    color: white;
    border-width: 10px;
    border-color: #cc0b0b;
}

.btn-primary {
    background: var(--brand);
    color: white;
}

.btn-secondary {
    background: #e9eef6;
    color: #0b1b2b;
}

.error {
    color: var(--error);
    font-size: 0.85rem;
}

footer {
    padding: 14px 20px 20px;
    color: var(--muted);
}

.section-divider {
    height: 1px;
    background: var(--border);
    margin: 18px 0;
}


li {
    margin-left: 20px;
}

.checkboxGroup-error {
    border: 2px red solid;
    padding: 10px 10px 10px 10px;
}

/* Base reset for custom controls */
input[type="checkbox"],
input[type="radio"] {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    margin: 0 8px 0 0;
    border: 2px solid var(--border);
    border-radius: 6px; /* square for checkbox; we’ll round radios below */
    display: inline-grid;
    place-content: center;
    background: #fff;
    cursor: pointer;
}

    /* Checkbox tick */
    input[type="checkbox"]::before {
        content: "";
        width: 12px;
        height: 12px;
        transform: scale(0);
        transition: transform 120ms ease-in-out;
        background: #005ea5; /* brand color */
        clip-path: polygon(14% 44%, 0 62%, 50% 100%, 100% 18%, 81% 0, 43% 62%);
        /* the clip-path above approximates a tick; you can swap for a square fill if preferred */
    }

    /* When checked, show tick */
    input[type="checkbox"]:checked::before {
        transform: scale(1);
    }

/* Radio circle */
input[type="radio"] {
    border-radius: 50%;
}

    /* Radio dot */
    input[type="radio"]::before {
        content: "";
        width: 12px;
        height: 12px;
        border-radius: 50%;
        transform: scale(0);
        transition: transform 120ms ease-in-out;
        background: #005ea5;
    }

    /* When checked, show dot */
    input[type="radio"]:checked::before {
        transform: scale(1);
    }

    /* Focus ring */
    input[type="checkbox"]:focus,
    input[type="radio"]:focus {
        outline: 2px solid #99c7f0;
        outline-offset: 2px;
    }

header img {
    float: right;
    max-height: 63px; /* optional: keep it neat */
}

/* Force all text inputs and textareas to display uppercase */
input,
textarea {
    text-transform: uppercase;
}

/* Red highlight for invalid radio/checkbox groups */
.radio-group.invalid {
    outline: 2px solid #b00020;
    outline-offset: 4px;
    border-radius: 8px;
}

/*input[type="radio"]:required {
            outline: 2px solid #b00020;
            outline-offset: 4px;
            border-radius: 8px;
        }*/

input[type="radio"]:required:invalid {
    outline: 2px solid #b00020;
    outline-offset: 4px;
    border-radius: 8px;
}

/* Optional: show a small message style if you add one */
.radio-error {
    color: #b00020;
    font-size: 0.85rem;
    margin-top: 4px;
}

/* File drop area styles */
.drop-area {
    /*width: 300px;*/
    height: 200px;
    border: 2px dashed #ccc;
    border-radius: 5px;
    text-align: left;
    padding: 10px;
}

    .drop-area.active {
        border-color: #007bff;
    }

.file-list {
    list-style-type: none;
    padding: 0;
}

.file-list-item {
    display: flex;
    align-items: center;
    margin: 5px 0;
}

.remove-button {
    color: red;
    cursor: pointer;
    margin-left: 10px;
}


.parent {
    position: relative;
    margin: 0px;
    padding: 0px;
}

.child1 {
    position: absolute;
    margin: 0px;
    padding: 0px;
    left: 0px;
    right: 0px;
}

.child2 {
    position: absolute;
    margin: 0px;
    padding: 0px;
    top: 60px;
    left: 15px;
    right: 0px;
}


.signature-pad--body {
    border: 1px solid #040404;
    width: 80%;
}

    .signature-pad--body
    canvas {
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        min-height: 150px;
        border-radius: 4px;
        box-shadow: 0 0 5px rgba(0, 0, 0, 0.02) inset;
    }

.signature-pad--actions {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    margin-top: 8px;
}

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.popup-box {
    background: #fff;
    padding: 20px;
    width: 300px;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    text-align: left;
}

.popup-box h3 {
    margin-top: 0;
    text-align: center;
}

.popup-box h4 {
    text-align: center;
}

.popup-box label {
    font-size: 14px;
    margin-top: 10px;
    display: block;
}

.popup-box input {
    width: 100%;
    padding: 8px;
    margin-top: 5px;
    box-sizing: border-box;
}

.popup-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
}

.popup-actions button {
    padding: 8px 12px;
    border: none;
    cursor: pointer;
    border-radius: 4px;
}

.popup-actions button.cancel {
    background: #ccc;
}

/* Kitchen TA10 tables only (those with Fitted + Free-standing) */
.ta10-kitchen-table {
  table-layout: fixed;
  width: 100%;
}

.ta10-kitchen-table th:nth-child(2),
.ta10-kitchen-table th:nth-child(3),
.ta10-kitchen-table th:nth-child(4),
.ta10-kitchen-table th:nth-child(5),
.ta10-kitchen-table th:nth-child(6),
.ta10-kitchen-table td:nth-child(2),
.ta10-kitchen-table td:nth-child(3),
.ta10-kitchen-table td:nth-child(4),
.ta10-kitchen-table td:nth-child(5),
.ta10-kitchen-table td:nth-child(6) {
  width: 70px;
  text-align: center;
  vertical-align: middle;
}

