:root {
    --navy: #1f3864;
    --gold: #b8860b;
    --light: #edeaea;
    --bg: #f4f6f9;
}

* { box-sizing: border-box; }

body {
    font-family: "Segoe UI", Arial, sans-serif;
    background: var(--bg);
    color: #222;
    margin: 0;
    padding: 24px 12px 60px;
}

.wrapper {
    max-width: 820px;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,.08);
    padding: 32px 36px 40px;
}

header.brand {
    text-align: center;
    border-bottom: 3px solid var(--gold);
    padding-bottom: 14px;
    margin-bottom: 24px;
}
header.brand h1 { color: var(--navy); margin: 0 0 4px; font-size: 26px; }
header.brand p.tagline { margin: 0 0 8px; font-style: italic; color: #666; }
header.brand p.form-title { margin: 0; font-weight: 700; font-size: 18px; }

.ref-box {
    background: #fff4d9;
    border: 1px solid #e4d199;
    border-radius: 4px;
    padding: 10px 14px;
    margin-bottom: 22px;
    font-weight: 600;
    color: #6b5300;
}

h2.section {
    background: var(--navy);
    color: #fff;
    padding: 8px 14px;
    border-radius: 4px;
    font-size: 16px;
    margin: 28px 0 14px;
}

h3.subsection {
    color: var(--navy);
    font-size: 15px;
    margin: 18px 0 10px;
}

.field {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    border: 1px solid #ccc;
    border-top: none;
}
.field:first-of-type { border-top: 1px solid #ccc; }
.field label {
    flex: 0 0 260px;
    background: var(--light);
    padding: 10px 12px;
    font-weight: 600;
    font-size: 14px;
}
.field .control {
    flex: 1;
    padding: 8px 12px;
    min-width: 220px;
}
.field input[type=text],
.field input[type=email],
.field input[type=tel],
.field input[type=date],
.field select,
.field textarea {
    width: 100%;
    padding: 7px 9px;
    border: 1px solid #bbb;
    border-radius: 4px;
    font-size: 14px;
}
.field textarea { min-height: 60px; resize: vertical; }

.radio-group label {
    background: none;
    flex: none;
    font-weight: 400;
    margin-right: 18px;
    padding: 0;
}
.radio-group { padding: 8px 12px; }

.guarantor-box {
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-bottom: 18px;
    overflow: hidden;
}
.guarantor-box .g-title {
    background: #e4eaf3;
    padding: 8px 12px;
    font-weight: 700;
    color: var(--navy);
}

.checklist { margin: 6px 0 14px; padding-left: 4px; list-style: none; }
.checklist li { margin-bottom: 8px; font-size: 14px; }
.checklist input { margin-right: 8px; }

.note {
    font-size: 13px;
    color: #555;
    background: #f0f3f7;
    border-left: 3px solid var(--navy);
    padding: 8px 12px;
    margin: 10px 0 6px;
}

.file-upload {
    border: 1px dashed #999;
    border-radius: 4px;
    padding: 12px;
    background: #fafafa;
}

button.submit-btn {
    display: block;
    width: 100%;
    background: var(--navy);
    color: #fff;
    border: none;
    padding: 14px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    margin-top: 26px;
}
button.submit-btn:hover { background: #16294c; }

.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}
.alert.success { background: #e3f6e6; border: 1px solid #9fd7a8; color: #1f6d2a; }
.alert.error   { background: #fdecec; border: 1px solid #f0a6a6; color: #8a1c1c; }

footer.foot {
    text-align: center;
    font-size: 12px;
    color: #999;
    border-top: 1px solid #e2e2e2;
    margin-top: 30px;
    padding-top: 12px;
}
