/* =========================================================================
   og / pages / contact

   Shared by Contact-Us and Partner-With-Us. Loaded via _OgLayout's "styles"
   section, not from og-design-system.css.

   The legacy pages used a 4/8 Bootstrap column split with the contact details
   on the left and the form on the right (Contact-Us), and a single full-width
   column (Partner-With-Us). Both are reproduced here with CSS Grid.
   ========================================================================= */

/* -------------------------------------------------------------------------
   Contact-Us two-column arrangement
   Legacy: .col-lg-4 details + .col-lg-8 form.
   ------------------------------------------------------------------------- */

.og-contact {
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    gap: var(--og-space-8);
    align-items: start;
}

.og-contact__aside { min-width: 0; }
.og-contact__main { min-width: 0; }

.og-contact__list {
    display: flex;
    flex-direction: column;
    gap: var(--og-space-4);
    margin: 0;
    padding: 0;
    list-style: none;
}

.og-contact__item {
    display: flex;
    align-items: center;
    gap: var(--og-space-3);
}

.og-contact__icon {
    flex: none;
    width: 34px;
    height: 34px;
    object-fit: contain;
}

.og-contact__item a {
    word-break: break-word;
    text-decoration: none;
}

.og-contact__item a:hover { text-decoration: underline; }

/* -------------------------------------------------------------------------
   Form layout
   Legacy: Name / Phone / Email across three half-width columns, Message and
   the submit button full width. The grid below keeps that arrangement while
   letting single-column stacking happen without a breakpoint fight.
   ------------------------------------------------------------------------- */

.og-contact-form__grid {
    --og-grid-gap: var(--og-space-5);
    align-items: start;
}

/* -------------------------------------------------------------------------
   Validation summary
   The asp-validation-summary tag helper renders a <ul>; it is styled here to
   sit inside the design system's alert component.
   ------------------------------------------------------------------------- */

.og-alert__summary ul {
    margin: 0;
    padding-left: var(--og-space-5);
}

.og-alert__summary li + li { margin-top: var(--og-space-1); }

/* The tag helper adds this class when the model is valid; it must never show. */
.og-alert__summary .validation-summary-valid { display: none; }

/* -------------------------------------------------------------------------
   Responsive
   Breakpoints match responsive/og-responsive.css: 991 / 767.
   ------------------------------------------------------------------------- */

@media (max-width: 991px) {
    .og-contact {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--og-space-6);
    }
}

@media (max-width: 767px) {
    /* One field per row, and a full-width submit control so the tap target
       spans the column. */
    .og-contact-form__grid { grid-template-columns: minmax(0, 1fr); }

    .og-form__actions,
    .og-form__actions .og-btn { width: 100%; }
}

/* -------------------------------------------------------------------------
   DPDP Act 2023 Consent Styling
   ------------------------------------------------------------------------- */

.og-consent-block {
    display: flex;
    flex-direction: column;
    gap: var(--og-space-2);
    margin-top: var(--og-space-2);
    margin-bottom: var(--og-space-1);
}

.og-consent-label {
    display: flex;
    align-items: flex-start;
    gap: var(--og-space-3);
    cursor: pointer;
    font-size: var(--og-font-size-sm);
    color: var(--og-color-ink);
    line-height: 1.45;
}

.og-consent-checkbox {
    flex: none;
    width: 1.25rem;
    height: 1.25rem;
    margin-top: 0.125rem;
    cursor: pointer;
    accent-color: var(--og-color-primary);
}

.og-consent-checkbox:disabled {
    cursor: not-allowed;
    opacity: 0.85;
}

.og-consent-text a {
    color: var(--og-color-primary-dark);
    text-decoration: underline;
    font-weight: var(--og-font-weight-medium);
}

.og-consent-text a:hover {
    color: var(--og-color-primary);
}

.og-consent-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--og-space-2);
    padding: var(--og-space-1) var(--og-space-3);
    border-radius: var(--og-radius-pill);
    font-size: var(--og-font-size-xs, 0.75rem);
    font-weight: var(--og-font-weight-semibold);
    background-color: var(--og-color-primary-subtle);
    color: var(--og-color-primary-dark);
    border: 1px solid rgba(4, 151, 170, 0.2);
    width: fit-content;
}

.og-consent-badge--active {
    background-color: var(--og-color-success-subtle);
    color: var(--og-color-success);
    border-color: rgba(34, 163, 89, 0.25);
}

.og-consent-error {
    margin-top: var(--og-space-1);
    color: var(--og-color-danger);
    font-size: var(--og-font-size-sm);
    font-weight: var(--og-font-weight-medium);
}

.og-withdraw-trigger {
    background: transparent;
    border: 1px solid var(--og-color-border-strong);
    color: var(--og-color-ink-muted);
    font-size: var(--og-font-size-sm);
    padding: var(--og-space-2) var(--og-space-4);
    border-radius: var(--og-radius-sm);
    cursor: pointer;
    transition: all var(--og-duration-fast) var(--og-easing-standard);
}

.og-withdraw-trigger:hover {
    background-color: var(--og-color-surface-muted);
    color: var(--og-color-danger);
    border-color: var(--og-color-danger);
}

/* -------------------------------------------------------------------------
   Accessible Modal Components (OTP & Withdraw Consent)
   ------------------------------------------------------------------------- */

.og-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(25, 26, 32, 0.65);
    z-index: var(--og-z-overlay);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--og-space-4);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--og-duration-base) var(--og-easing-standard),
                visibility var(--og-duration-base) var(--og-easing-standard);
}

.og-modal-backdrop.is-open {
    opacity: 1;
    visibility: visible;
}

.og-modal-dialog {
    background-color: var(--og-color-surface);
    border-radius: var(--og-radius-md);
    box-shadow: var(--og-shadow-lg);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: translateY(16px);
    transition: transform var(--og-duration-base) var(--og-easing-standard);
}

.og-modal-backdrop.is-open .og-modal-dialog {
    transform: translateY(0);
}

.og-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--og-space-5) var(--og-space-6);
    border-bottom: var(--og-border-width) solid var(--og-color-border);
}

.og-modal-title {
    margin: 0;
    font-size: var(--og-font-size-lg, 1.25rem);
    font-weight: var(--og-font-weight-bold);
    color: var(--og-color-ink);
}

.og-modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    color: var(--og-color-ink-muted);
    cursor: pointer;
    padding: var(--og-space-1);
    border-radius: var(--og-radius-sm);
}

.og-modal-close:hover {
    color: var(--og-color-ink);
}

.og-modal-body {
    padding: var(--og-space-6);
    display: flex;
    flex-direction: column;
    gap: var(--og-space-4);
}

.og-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: var(--og-space-3);
    padding: var(--og-space-4) var(--og-space-6);
    border-top: var(--og-border-width) solid var(--og-color-border);
    background-color: var(--og-color-surface-muted);
}

.og-otp-input {
    font-size: 1.75rem !important;
    font-weight: var(--og-font-weight-bold);
    letter-spacing: 0.5em;
    text-align: center;
    padding: var(--og-space-3) var(--og-space-4);
    font-family: monospace;
}

.og-modal-input {
    width: 100%;
    padding: var(--og-space-3) var(--og-space-4);
    color: var(--og-color-ink);
    background-color: var(--og-color-surface);
    border: var(--og-border-width) solid var(--og-color-border-strong);
    border-radius: var(--og-radius-sm);
    transition: border-color var(--og-duration-fast) var(--og-easing-standard),
                box-shadow var(--og-duration-fast) var(--og-easing-standard);
}

.og-modal-input:focus {
    border-color: var(--og-color-primary);
    box-shadow: var(--og-focus-ring);
    outline: none;
}

.og-timer-info {
    font-size: var(--og-font-size-sm);
    color: var(--og-color-ink-muted);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.og-timer-badge {
    font-weight: var(--og-font-weight-semibold);
    color: var(--og-color-primary-dark);
}

.og-timer-badge--expiring {
    color: var(--og-color-danger);
}

.og-char-counter {
    font-size: var(--og-font-size-xs, 0.75rem);
    color: var(--og-color-ink-muted);
    text-align: right;
    margin-top: calc(-1 * var(--og-space-2));
}
