/* =========================================================
   Summit Rock Advisors - Modernized site stylesheet
   Replaces the legacy maincss.css / main.css / lightbox CSS
   ========================================================= */

:root {
    --color-text: #455560;
    --color-muted: #999;
    --color-rule: #b4b7b9;
    --color-bg-home: #333;
    --color-bg-page: #fff;
    --color-link: #455560;
    --color-link-hover: #1f2a30;
    --font-serif: "Times New Roman", Times, serif;
    --font-display: Perpetua, "Times New Roman", Times, serif;
    --content-max: 1020px;
}

/* Modern reset */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

body {
    font-family: var(--font-serif);
    font-size: 16px;
    line-height: 1.4;
    color: var(--color-text);
    background-color: var(--color-bg-page);
    -webkit-font-smoothing: antialiased;
}

/* =========================================================
   Home page (matches the legacy dark landing page)
   ========================================================= */
body.home {
    background-color: var(--color-bg-home);
    color: #fff;
    padding-top: 5px;
}

.home-header {
    width: 30%;
    margin: 0 0 0 10px;
    font-family: var(--font-display);
    font-size: 11pt;
}

.home-header .address {
    color: var(--color-muted);
    margin: 0;
    line-height: 1.2;
}

.home-header .contact-link {
    color: #fff;
    text-decoration: underline;
}

.home-header .contact-link:hover,
.home-header .contact-link:focus {
    text-decoration: none;
}

.home-logo {
    width: 100%;
    text-align: center;
}

.home-logo img {
    width: 182px;
    height: 182px;
    display: inline-block;
    border: 0;
}

/* =========================================================
   Bio pages (matches existing bio/css/main.css visuals)
   ========================================================= */
.container {
    position: relative;
    margin: 50px auto;
    max-width: var(--content-max);
    padding: 0 20px;
}

.site-header .logo {
    display: block;
    margin: 0 0 30px;
    width: 127px;
    height: 85px;
}

.bio {
    border-top: 1px solid var(--color-rule);
    border-bottom: 1px solid var(--color-rule);
    padding: 10px 0 12px;
    display: grid;
    grid-template-columns: 140px 1fr 190px;
    gap: 0;
}

.bio .left-column {
    padding-right: 25px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text);
}

.bio .content-column {
    padding: 0 65px 0 0;
}

.bio .content-column p { margin: 0 0 20px; }

.bio .content-column a,
.bio .content-column a:visited {
    color: var(--color-link);
    text-decoration: none;
    border-bottom: 1px solid var(--color-link);
}

.bio .content-column a:hover,
.bio .content-column a:focus {
    color: var(--color-link-hover);
    border-bottom-color: var(--color-link-hover);
}

.bio .content-column sup { font-size: 10px; vertical-align: super; }

.bio .content-column .footnote {
    font-size: 12px;
    font-style: italic;
    margin-top: 70px;
}

.bio .right-column { text-align: right; }
.bio .right-column img { width: 100%; }

.site-footer {
    clear: both;
    padding-top: 10px;
    font-size: 0.8125em;
    opacity: 0.5;
}

@media (max-width: 700px) {
    .container { margin: 20px auto; }
    .bio {
        grid-template-columns: 1fr;
        padding: 10px 0 30px;
    }
    .bio .left-column {
        padding: 0;
        margin-bottom: 24px;
    }
    .bio .content-column { padding: 0; }
    .bio .content-column .footnote { margin: 30px 0; }
    .bio .right-column { text-align: left; margin-top: 20px; }
}

/* =========================================================
   Contact page (matches legacy form.php exactly)
   ========================================================= */
body.home form,
body.home form td,
body.home form input,
body.home form textarea {
    color: #000;
    font-family: Arial, sans-serif;
}

.inputtxt {
    font-family: Arial, sans-serif;
    border: 1px solid #000;
    text-decoration: none;
    width: 150px;
    font-size: 12px;
    padding: 1px 2px;
}

textarea.inputtxt {
    width: 194px;
}

/* Submit/Cancel buttons on the legacy contact form intentionally use the
   browser-default control look (light gray, black text). Do not style. */
.btn {
    font-family: Arial, sans-serif;
    font-size: 12px;
    cursor: pointer;
}

.messageblue {
    font-weight: bold;
    color: blue;
    font-size: 11px;
    font-family: Arial, sans-serif;
}

.form-status {
    font-family: Arial, sans-serif;
    font-size: 11px;
    font-weight: bold;
    min-height: 1.2em;
    padding-top: 6px;
}
.form-status.success { color: green; }
.form-status.error   { color: red; }

@media (max-width: 700px) {
    body.home {
        padding: 5px 12px 24px;
    }

    .home-header {
        width: auto;
        margin: 0 auto 20px;
        text-align: center;
    }

    .home-logo img {
        width: min(182px, 48vw);
        height: auto;
    }

    .contact-page {
        max-width: 420px;
        margin: 0 auto;
        padding: 0 0 24px;
    }

    .contact-shell,
    .contact-shell tbody,
    .contact-shell tr,
    .contact-shell td,
    .contact-panel,
    .contact-panel tbody,
    .contact-panel tr,
    .contact-panel td,
    .contact-form-table {
        display: block;
        width: 100% !important;
        height: auto !important;
        margin: 0 auto;
    }

    .contact-panel {
        background-color: #fff;
        padding: 12px;
    }

    .contact-layout-row,
    .contact-spacer-row {
        display: none;
    }

    .contact-form-table,
    .contact-form-table tbody,
    .contact-form-table tr,
    .contact-form-table td {
        display: block;
    }

    .contact-field,
    .contact-captcha,
    .contact-actions,
    .contact-status-row {
        width: 100%;
        margin-bottom: 12px;
    }

    .contact-captcha {
        overflow: hidden;
    }

    .contact-field td,
    .contact-captcha td,
    .contact-actions td,
    .contact-status-row td {
        width: 100% !important;
        height: auto !important;
    }

    .contact-field td:not(.contact-label):not(.contact-input),
    .contact-captcha td:not(.contact-input),
    .contact-actions td:not(.contact-input),
    .contact-status-row td:not(.contact-input) {
        display: none;
    }

    .contact-label {
        padding: 0 0 4px;
    }

    .contact-label div {
        text-align: left !important;
    }

    .contact-input {
        padding: 0;
    }

    .contact-actions .contact-input {
        display: flex;
        gap: 8px;
        align-items: center;
        flex-wrap: wrap;
    }

    .contact-actions .contact-input a {
        display: inline-flex;
    }

    .contact-actions .btn {
        min-height: 32px;
        padding: 4px 10px;
    }

    .inputtxt,
    textarea.inputtxt {
        width: 100% !important;
        max-width: none;
    }

    .contact-captcha .contact-input {
        overflow-x: auto;
    }

    .contact-captcha .g-recaptcha {
        transform-origin: left top;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 15px;
    }

    .container {
        margin: 16px auto;
        padding: 0 14px;
    }

    .site-header .logo {
        margin-bottom: 20px;
    }

    .bio .left-column {
        letter-spacing: 0.06em;
        margin-bottom: 18px;
    }

    .bio .content-column p {
        margin-bottom: 16px;
    }

    .bio .right-column img {
        max-width: 260px;
        margin: 0 auto;
    }

    .contact-page {
        max-width: 100%;
    }

    .contact-panel {
        padding: 10px;
    }

    .contact-captcha .g-recaptcha {
        transform: scale(0.86);
        margin-bottom: -14px;
    }
}
