/* reliancecyber.ca - the public homepage. A static site on a Cloudflare Worker,
   separate from the portal, but the same look: the tokens below are copied
   from the portal's site.css, so a brand change is made in both.

   Phone rules live at the END of this file, as in the portal. */

:root {
    --bg:            #f4f5f7;
    --surface:       #ffffff;
    --border:        #e3e5e9;
    --border-strong: #d3d7de;
    --text:          #16181d;
    --text-muted:    #5c6370;
    --accent:        #1f4ed8;
    --accent-strong: #1740b4;
    --accent-fg:     #ffffff;
    --accent-soft:   #eef2fd;
    --accent-ring:   rgba(31, 78, 216, 0.18);

    --radius-sm: 8px;
    --radius:    12px;
    --radius-lg: 18px;

    --shadow:    0 1px 2px rgba(16, 24, 40, 0.04), 0 4px 16px rgba(16, 24, 40, 0.06);

    --font: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-display: "Segoe UI Variable Display", "Segoe UI", -apple-system, BlinkMacSystemFont, system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;

    --ease: cubic-bezier(0.2, 0, 0, 1);
    --page: 64rem;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(1200px 520px at 50% -160px, rgba(31, 78, 216, 0.10), transparent 70%),
        var(--bg);
    background-repeat: no-repeat;
    color: var(--text);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }
::selection { background: var(--accent-ring); }

h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.02em; line-height: 1.15; margin: 0 0 0.75rem; }
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); font-weight: 700; max-width: 20ch; }
h2 { font-size: 1.5rem; font-weight: 650; }
h3 { font-size: 1.1rem; font-weight: 650; letter-spacing: -0.01em; }
p { margin: 0 0 0.9rem; }

/* ---- Header ------------------------------------------------------------ */

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 1rem;
    min-height: 64px;
    padding: 0.75rem max(1.5rem, calc((100vw - var(--page)) / 2));
    background: rgba(255, 255, 255, 0.82);
    border-bottom: 1px solid rgba(227, 229, 233, 0.9);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    backdrop-filter: saturate(180%) blur(14px);
}

.home-link { display: flex; align-items: center; gap: 0.65rem; min-width: 0; color: inherit; text-decoration: none; }
.home-link:hover { color: inherit; }

.mark {
    flex: none;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: linear-gradient(140deg, #3b6cf0 0%, var(--accent) 55%, var(--accent-strong) 100%);
    box-shadow: 0 2px 6px rgba(31, 78, 216, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.site-name { font-family: var(--font-display); font-weight: 650; font-size: 1.02rem; letter-spacing: -0.01em; white-space: nowrap; }

.header-action { margin-left: auto; }

/* ---- Buttons ----------------------------------------------------------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 1.25rem;
    border: 1px solid var(--accent);
    border-radius: var(--radius-sm);
    background: var(--accent);
    color: var(--accent-fg);
    font: 600 0.95rem/1 var(--font);
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.08);
    transition: background 0.15s var(--ease), border-color 0.15s var(--ease);
}
.btn:hover { background: var(--accent-strong); border-color: var(--accent-strong); color: var(--accent-fg); }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--accent-ring); }

.btn-quiet { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-quiet:hover { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-strong); }

.btn-small { min-height: 36px; padding: 0 0.9rem; font-size: 0.88rem; }

/* ---- Content ----------------------------------------------------------- */

main { flex: 1; width: 100%; max-width: calc(var(--page) + 3rem); margin: 0 auto; padding: 0 1.5rem 3rem; }

.hero { padding: 5rem 0 3.5rem; }
.eyebrow { color: var(--accent); font-weight: 600; font-size: 0.85rem; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 1rem; }
.lead { font-size: 1.15rem; color: var(--text-muted); max-width: 40rem; margin-bottom: 1.75rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.section {
    margin-bottom: 1.5rem;
    padding: 2rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    scroll-margin-top: 80px;
}

.grid { display: grid; gap: 1rem; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card { padding: 1.25rem 1.35rem; border: 1px solid var(--border); border-radius: var(--radius); background: var(--accent-soft); }
.card p { margin: 0; color: var(--text-muted); }

.note { color: var(--text-muted); font-size: 0.92rem; margin: 1rem 0 0; }

.coverages {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem 1.5rem;
}
.coverages li { position: relative; padding-left: 1.6rem; }
.coverages li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.45em;
    width: 0.8rem;
    height: 0.45rem;
    border-left: 2px solid var(--accent);
    border-bottom: 2px solid var(--accent);
    transform: rotate(-45deg);
}

.split { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.split > div:first-child { max-width: 38rem; }
.split p:last-child { margin-bottom: 0; }
.button-col { display: flex; flex-direction: column; gap: 0.6rem; flex: none; }

.site-footer {
    padding: 1.5rem max(1.5rem, calc((100vw - var(--page)) / 2));
    color: var(--text-muted);
    font-size: 0.85rem;
    border-top: 1px solid var(--border);
}

/* ---- Phones ------------------------------------------------------------ */
/* Last on purpose: see the note at the top. */

@media (max-width: 640px) {
    .site-header { min-height: 58px; padding: 0.6rem 1rem; gap: 0.75rem; }
    .btn-small { min-height: 40px; }

    main { padding: 0 1rem 2.5rem; }
    .hero { padding: 2.5rem 0 2rem; }
    .lead { font-size: 1.05rem; }
    .hero-actions .btn, .button-col .btn { width: 100%; min-height: 48px; }

    .section { padding: 1.35rem 1.15rem; border-radius: var(--radius); margin-bottom: 1rem; }
    .grid.two, .coverages { grid-template-columns: 1fr; }
    .split { flex-direction: column; align-items: stretch; gap: 1.25rem; }

    .site-footer { padding: 1rem; }
}
