/* ═══════════════════════════════════════════════════════════
   KCGF Matrimony Form Styles
   Elegant, warm palette — ivory/gold/burgundy
   Step transitions use CSS animations
═══════════════════════════════════════════════════════════ */

.kcgf-mat-wrap { --mat-gold: #b8922e; --mat-burgundy: #7c1d2a; --mat-ivory: #fdf8f0; }

.kcgf-mat-step2-title {
    font-size: 22px !important;
    line-height: 1.25;
}

.kcgf-mat-wrap .kcgf-surname-item {
    justify-content: flex-start;
    gap: 0;
}

.kcgf-mat-wrap .kcgf-surname-item-gotram {
    margin-left: auto;
    flex: 0 1 55%;
}

/* ── Step transition animation ── */
.kcgf-mat-step { display:none; }
.kcgf-mat-step.is-active { display:block; animation:kcgf-slide-in .35s cubic-bezier(.4,0,.2,1); }
.kcgf-mat-step.is-exiting { animation:kcgf-slide-out .25s cubic-bezier(.4,0,.2,1) forwards; }
@keyframes kcgf-slide-in  { from{opacity:0;transform:translateX(24px)} to{opacity:1;transform:translateX(0)} }
@keyframes kcgf-slide-out { from{opacity:1;transform:translateX(0)} to{opacity:0;transform:translateX(-24px)} }

/* ── STEP 1 — Intent screen ── */
.kcgf-mat-intent-screen {
    padding: 20px 10px 10px;
    text-align: center;
}
.kcgf-mat-intent-header { margin-bottom: 36px; }
.kcgf-mat-cross {
    font-size: 40px; color: var(--mat-gold);
    display: block; margin-bottom: 8px; line-height:1;
}
.kcgf-mat-intent-header h2 {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 34px; font-weight: 700;
    color: var(--navy); margin: 0 0 4px;
}
.kcgf-mat-intent-header p { font-size:14px; color:var(--text-mid); margin:2px 0; }
.kcgf-mat-subtitle { font-size:13px; color:var(--text-lt); margin-top:6px !important; }

.kcgf-mat-intent-question > p {
    font-size: 18px; font-weight: 600;
    color: var(--text); margin-bottom: 24px;
}
.kcgf-mat-intent-cards {
    display: flex; justify-content: center;
    gap: 24px; flex-wrap: wrap; margin-bottom: 32px;
}
.kcgf-mat-intent-card {
    display: flex; flex-direction: column; align-items: center;
    gap: 10px; padding: 28px 36px;
    border: 2px solid var(--border); border-radius: 12px;
    background: var(--white); cursor: pointer;
    transition: all .2s; min-width: 150px;
    position: relative;
}
.kcgf-mat-intent-card input[type="radio"] {
    position: absolute; opacity: 0; width: 0; height: 0;
}
.kcgf-mat-intent-card:hover { border-color: var(--navy-mid); box-shadow: 0 4px 16px rgba(15,33,86,.1); }
.kcgf-mat-intent-card.is-selected {
    border-color: var(--navy); background: var(--navy-lt);
    box-shadow: 0 0 0 3px rgba(15,33,86,.12);
}
.kcgf-mat-card-icon { font-size: 44px; line-height:1; }
.kcgf-mat-card-title { font-size: 18px; font-weight: 700; color: var(--navy); }
.kcgf-mat-card-sub   { font-size: 14px; color: var(--text-mid); font-family: serif; }

/* ── Photo upload section ── */
.kcgf-mat-photo-section {
    margin-top: 24px; padding-top: 20px;
    border-top: 1px dashed var(--border);
}
.kcgf-mat-subsection-title {
    font-size: 12px; font-weight: 700; text-transform: uppercase;
    letter-spacing: .5px; color: var(--text-mid); margin: 0 0 6px;
}
.kcgf-mat-photo-hint { font-size:12px; color:var(--text-lt); margin:0 0 14px; }

.kcgf-mat-photo-upload-area {
    display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap;
}
.kcgf-mat-main-photo-wrap { flex-shrink: 0; }
.kcgf-mat-photo-drop {
    position: relative; width: 140px; height: 175px;
    border: 2px dashed var(--border); border-radius: 6px;
    background: var(--ivory); cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden; transition: border-color var(--ease);
}
.kcgf-mat-photo-drop:hover { border-color: var(--navy-mid); background: var(--navy-lt); }
.kcgf-mat-photo-drop-inner {
    display: flex; flex-direction: column; align-items: center;
    gap: 6px; color: var(--text-lt); font-size: 12px;
    text-align: center; padding: 12px; pointer-events: none;
}
.kcgf-mat-photo-drop-inner svg { width: 36px; height: 36px; }
.kcgf-mat-photo-drop-inner small { font-size: 10px; color: var(--text-lt); }
#kcgf-mat-main-preview { width:100%; height:100%; object-fit:cover; display:block; }
.kcgf-mat-photo-remove {
    position: absolute; top: 4px; right: 4px;
    width: 22px; height: 22px; border-radius: 50%;
    background: rgba(0,0,0,.55); border: none; color: #fff;
    font-size: 13px; cursor: pointer; display: flex;
    align-items: center; justify-content: center; transition: background .15s;
}
.kcgf-mat-photo-remove:hover { background: var(--red); }

/* Extra photos grid */
.kcgf-mat-extra-photos { flex: 1; }
.kcgf-mat-extra-grid {
    display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px;
}
.kcgf-mat-extra-thumb {
    position: relative; width: 90px; height: 112px;
    border-radius: 4px; overflow: hidden;
    border: 1.5px solid var(--border);
}
.kcgf-mat-extra-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.kcgf-mat-extra-thumb .kcgf-mat-photo-remove { top:2px; right:2px; width:18px; height:18px; font-size:11px; }

.kcgf-mat-add-photo-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 14px; border: 1.5px dashed var(--navy-mid);
    border-radius: var(--rsm); color: var(--navy-mid);
    background: var(--navy-lt); font-size: 13px; font-weight: 600;
    cursor: pointer; transition: all .15s; font-family: 'DM Sans',sans-serif;
}
.kcgf-mat-add-photo-btn:hover { background: var(--navy); color: #fff; border-style: solid; }
.kcgf-mat-add-photo-btn svg { width:15px; height:15px; }

/* ── Siblings section ── */
.kcgf-mat-siblings-section { margin-top: 24px; }
.kcgf-mat-sibling-card {
    background: var(--ivory); border: 1px solid var(--border);
    border-radius: var(--rsm); padding: 16px; margin-bottom: 12px;
    position: relative;
}
.kcgf-mat-sibling-card .kcgf-fields-grid { margin-bottom: 0; }
.kcgf-mat-remove-sibling {
    position: absolute; top: 10px; right: 10px;
    width: 26px; height: 26px; border-radius: 50%;
    border: 1.5px solid #fca5a5; background: none; color: var(--red);
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 14px; transition: all .15s; padding: 0;
}
.kcgf-mat-remove-sibling:hover { background: var(--red); color: #fff; border-color: var(--red); }

/* ── Preferences sliders ── */
.kcgf-mat-pref-block {
    background: var(--ivory); border: 1px solid var(--border);
    border-radius: var(--rsm); padding: 18px 20px; margin-bottom: 14px;
}
.kcgf-mat-pref-label {
    display: block; font-size: 13px; font-weight: 600;
    color: var(--text-mid); margin-bottom: 10px;
}
.kcgf-mat-range-row { margin-bottom: 10px; }
.kcgf-mat-range-row span {
    font-size: 16px; font-weight: 700; color: var(--navy);
}
.kcgf-mat-dual-range { position: relative; height: 36px; }
.kcgf-mat-range {
    width: 100% !important; appearance: none !important; -webkit-appearance: none !important;
    height: 4px !important; background: var(--border) !important;
    border: none !important; border-radius: 2px !important;
    outline: none !important; cursor: pointer !important;
    position: absolute; top: 16px; left: 0;
    padding: 0 !important; margin: 0 !important;
    pointer-events: auto;
}
.kcgf-mat-range::-webkit-slider-thumb {
    -webkit-appearance: none; width: 20px; height: 20px;
    border-radius: 50%; background: var(--navy);
    border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.2);
    cursor: pointer; position: relative; z-index: 2;
}
.kcgf-mat-range::-moz-range-thumb {
    width: 20px; height: 20px; border-radius: 50%; background: var(--navy);
    border: 3px solid #fff; cursor: pointer;
}
.kcgf-mat-select {
    width: 100%; padding: 10px 14px !important;
    border: 1.5px solid var(--border) !important;
    border-radius: var(--rsm) !important; font-size: 14px !important;
    background: var(--white) !important; color: var(--text) !important;
    -webkit-appearance: none !important; appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%234a5880' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important; background-position: right 12px center !important;
    padding-right: 36px !important;
}
.kcgf-mat-radio-group { display: flex; flex-direction: column; gap: 10px; }
.kcgf-mat-radio {
    display: flex; align-items: center; gap: 10px;
    font-size: 14px; color: var(--text); cursor: pointer;
}
.kcgf-mat-radio input[type="radio"] {
    width: 16px !important; height: 16px !important; min-width: 16px !important;
    -webkit-appearance: radio !important; appearance: radio !important;
    accent-color: var(--navy); cursor: pointer; margin: 0 !important; padding: 0 !important;
    border: none !important; background: none !important;
}

/* ── Disclaimer ── */
.kcgf-mat-disclaimer {
    background: #fff9f0; border: 1px solid #f0d9b0;
    border-left: 4px solid var(--mat-gold); border-radius: var(--rsm);
    padding: 18px 20px; margin-bottom: 20px;
}
.kcgf-mat-disclaimer h4 { font-size:14px; font-weight:700; color:#7c4a00; margin:0 0 10px; }
.kcgf-mat-disclaimer ul { margin:0; padding-left:18px; }
.kcgf-mat-disclaimer li { font-size:13px; color:#555; margin-bottom:8px; line-height:1.6; }
.kcgf-mat-submitter-section { margin-bottom: 20px; }

/* Terms checkbox */
.kcgf-mat-terms-row { margin-bottom: 20px; }
.kcgf-mat-terms-label {
    display: flex; align-items: flex-start; gap: 10px;
    font-size: 13px; color: var(--text); cursor: pointer;
    padding: 12px 14px; background: #f8f5ef;
    border: 1px solid #e5d9c0; border-radius: var(--rsm);
}
.kcgf-mat-terms-check {
    flex-shrink: 0; margin-top: 2px !important;
    width: 16px !important; height: 16px !important; min-width: 16px !important;
    -webkit-appearance: checkbox !important; appearance: checkbox !important;
    accent-color: var(--navy) !important; cursor: pointer !important;
    border: none !important; background: none !important;
    padding: 0 !important;
}

/* ── Admin badges ── */
.kcgf-mat-badge {
    display: inline-block; padding: 3px 10px; border-radius: 999px;
    font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .4px;
}
.kcgf-mat-badge--bride { background: #fce7f3; color: #9d174d; }
.kcgf-mat-badge--groom { background: #dbeafe; color: #1e3a8a; }

/* ── Admin photo gallery ── */
.kcgf-mat-admin-photos {
    display: flex; flex-wrap: wrap; gap: 10px;
    margin-bottom: 24px;
}
.kcgf-mat-admin-photo {
    width: 110px; height: 138px; object-fit: cover;
    border-radius: 4px; border: 1px solid #dde3f0;
}
.kcgf-mat-admin-photo--main {
    width: 140px; height: 175px;
    border: 3px solid var(--navy-mid);
}

/* ── Responsive ── */
@media (max-width:640px) {
    .kcgf-mat-intent-cards { gap: 14px; }
    .kcgf-mat-intent-card  { padding: 20px 24px; min-width: 130px; }
    .kcgf-mat-card-icon    { font-size: 36px; }
    .kcgf-mat-step2-title  { font-size: 20px !important; }
}

/* ── Step transition animation ───────────────────── */
.kcgf-mat-step {
    transition: opacity .25s ease, transform .25s ease;
}
.kcgf-mat-step.kcgf-mat-slide-out {
    opacity: 0;
    transform: translateX(-20px);
    pointer-events: none;
}
.kcgf-mat-step.is-active {
    animation: kcgf-mat-slidein .28s ease;
}
@keyframes kcgf-mat-slidein {
    from { opacity: 0; transform: translateX(20px); }
    to   { opacity: 1; transform: translateX(0); }
}
