:root {
    /* refined, professional palette */
    --primary-500: #0ea5e9;    /* bright cyan */
    --primary-700: #0369a1;    /* deep cyan */
    --accent-500: #ff7a59;     /* warm coral */
    --muted-800: #0b2447;      /* deep navy */
    --muted-900: #071229;      /* near-black navy */
    --muted-600: #2b475f;      /* slate */
    --card-start: #ffffff;
    --card-end: #f3fbff;
    --muted-contrast: #0f1724;
}

/* Header: deep navy gradient */
header {
    background: linear-gradient(90deg, var(--muted-800), var(--primary-700));
    box-shadow: 0 2px 12px rgba(7,18,41,0.08);
}

/* Navbar links refined */
.nav-links li a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    padding: 0.5rem 0.9rem;
    border-radius: 16px;
    transition: background 0.18s, color 0.18s, box-shadow 0.18s;
}
.nav-links li a:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
    box-shadow: 0 6px 18px rgba(3,38,76,0.12);
}

/* Dropdown link color */
.dropdown-content li a {
    color: var(--muted-800);
}
.dropdown-content li a:hover {
    background: var(--primary-500);
    color: #fff;
}

/* Instructions block: subtle teal accent */
.instructions-block {
    background: #f6fffb;
    border: 1.25px solid rgba(6,139,124,0.12);
    border-radius: 14px;
    box-shadow: 0 4px 18px rgba(11,36,71,0.03);
    padding: 1.2rem;
    margin: 1.2rem auto;
    color: #0b3a3a;
}
.instructions-block strong { color: var(--primary-700); }
.instructions-block em { color: var(--muted-600); }

/* Hero: softer professional styling */
.hero {
    padding: 2.5rem 1rem 1.5rem 1rem;
    text-align: center;
    background: linear-gradient(180deg, #ffffff, #f7fbff);
    color: var(--muted-900);
    border-radius: 0 0 24px 24px;
    box-shadow: 0 10px 40px rgba(3,38,76,0.04);
    margin-bottom: 1.6rem;
}
.hero h1 {
    font-size: 2.4rem;
    margin-bottom: 0.5rem;
    font-weight: 800;
    letter-spacing: 1px;
    color: var(--muted-900);
}
.hero .lead { color: var(--muted-600); }

/* Calculator container: subtle cooler card */
.calculator-container {
    background: linear-gradient(180deg, var(--card-start), var(--card-end));
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(3,38,76,0.06), inset 0 1px 0 rgba(255,255,255,0.6);
}

/* Buttons: keep cyan primary, improve contrast */
.calculator-container .btn-calc,
.calculator-container button {
    background: linear-gradient(180deg,var(--primary-500),var(--primary-700));
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(3,38,76,0.10);
}
.calculator-container .btn-secondary {
    background: linear-gradient(180deg,#f3f6f9,#e9f2f8);
    color: var(--muted-900);
    border: 1px solid rgba(7,18,41,0.04);
}

/* Unit toggle active style */
.calculator-container .unit-toggle button.active {
    background: linear-gradient(180deg,var(--primary-500),var(--primary-700));
    color:#fff;
    border-color: transparent;
    box-shadow: 0 6px 20px rgba(3,38,76,0.08);
}

/* Calculator card: refined neutral tones */
.calculator-card {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border: 1px solid rgba(6,139,124,0.06);
    border-radius: 14px;
    padding: 1.25rem;
    box-shadow: 0 10px 30px rgba(3,38,76,0.05);
    max-width: 980px;
    margin: 1.2rem auto;
}
.calculator-card label {
    color: var(--muted-800);
    font-weight: 700;
}

/* Results: stronger accent for values */
.calculator-container .results strong {
    color: var(--primary-700);
    font-size: 1.08rem;
}

/* Links */
.internal-links a,
.outbound-links a {
    color: var(--primary-700);
    text-decoration: underline;
}
.internal-links a:hover,
.outbound-links a:hover {
    color: var(--accent-500);
}

/* Footer adjustments */
footer {
    background: linear-gradient(90deg,var(--muted-800),var(--primary-700));
    color: #fff;
}

/* Fine-tune small screen paddings */
@media (max-width: 600px) {
    .hero h1 { font-size: 1.8rem; }
    .calculator-container { padding: 0.9rem; }
}

/* Unit label for vertical leap */
.unit-label {
    display: block;
    margin-top: 2px;
    font-size: 0.98em;
    color: #888;
    letter-spacing: 0.01em;    
}

/* Rim Height Dropdown Custom Style */
select#hoop-type {
    width: 100%;
    padding: 0.6em 1.2em 0.6em 0.8em;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fafbfc;
    color: #222;
    font-size: 1rem;
    transition: border 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    appearance: none;
    outline: none;
}

select#hoop-type:focus {
    border-color: #ff8800;
    box-shadow: 0 0 0 2px rgba(255, 136, 0, 0.15);
}

select#hoop-type option {
    color: #222;
    background: #fff;
}

/* Instructions block styling */
.instructions-block {
    background: #fffbe7;
    border: 1.5px solid #ff8800;
    border-radius: 18px;
    box-shadow: 0 2px 12px rgba(255, 136, 0, 0.07);
    padding: 1.3rem 1.2rem 1.1rem 1.2rem;
    margin: 1.5rem auto 1.5rem auto;
    max-width: 90%;
    color: #6b2c00;
    font-size: 1.04rem;
    line-height: 1.6;
}

.instructions-block strong {
    color: #ff8800;
}

.instructions-block em {
    color: #b85c00;
    font-style: normal;
}

.instructions-block ol,
.instructions-block ul {
    margin-left: 1.2rem;
    margin-bottom: 0.7rem;
}

.instructions-block li {
    margin-bottom: 0.5rem;
}

body {
    margin: 0;
    font-family: 'Segoe UI', Arial, sans-serif;
    background: #ffffff;
    color: #222;
}

header {
    background: #ff8800;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.8rem 2rem;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    width: 40px;
    height: 40px;
    margin-right: 0.7rem;
}

.site-name {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
    letter-spacing: 1px;
}

/* Make header title a plain-looking clickable link:
   - no underline
   - no color change on hover
   - cursor pointer
   - preserve keyboard focus ring for accessibility */
  /* keep existing styles */
}

.site-name a,
.logo a.site-name {
  color: white;
  text-decoration: none;
  cursor: pointer;
  display: inline-block;
}

/* Prevent color/underline change on hover/focus */
.site-name a:hover,
.site-name a:focus,
.logo a.site-name:hover,
.logo a.site-name:focus {
  color: inherit;
  text-decoration: none;
  outline: none;
}

/* Keep an accessible focus-visible outline for keyboard users */
.site-name a:focus-visible,
.logo a.site-name:focus-visible {
  outline: 3px solid rgba(14,165,233,0.14);
  outline-offset: 3px;
  border-radius: 6px;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 1.2rem;
    margin: 0;
    padding: 0;
}

/* Submenu UL bullets hatane ke liye */
.nav-links .dropdown-content {
  list-style: none;   /* removes default bullets */
  margin: 0;
  padding: 0;
}

/* Submenu items alignment fix */
.nav-links .dropdown-content li {
  text-align: left;   /* text ko start/main se align karega */
  padding: 8px 12px;  /* spacing clean dikhane ke liye */
}

/* Optional: Links ko block banado taake poori line clickable ho */
.nav-links .dropdown-content li a {
  display: block;
  text-decoration: none;
  color: #333;  /* apni theme ke mutabiq color rakh sakte ho */
}

.nav-links li a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    transition: background 0.2s, color 0.2s;
}

.nav-links li a:hover {
    background: #fff;
    color: #ff8800;
    box-shadow: 0 2px 8px rgba(255, 136, 0, 0.15);
}

.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: #fff;
    min-width: 180px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    border-radius: 12px;
    top: 100%;
    left: 0;
    margin-top: 8px; /* overlap parent slightly to prevent cursor gap */
    z-index: 10;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* Keep dropdown visible when JS toggles the 'open' class (adds small delay handling) */
.dropdown.open .dropdown-content {
    display: block;
}


.dropdown-content li a {
    list-style: none;
    color: #6b2c00;
    padding: 0.7rem 1rem;
    display: block;
    border-radius: 10px;
}
ul.dropdown-content{
    list-style: none;
}

.dropdown-content li a:hover {
    background: #ff8800;
    color: #fff;
}

/* ===== Mobile Hamburger Menu Styles ===== */
.hamburger {
    display: none;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    padding: 0.5rem;
    cursor: pointer;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.hamburger:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.hamburger:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

/* Show hamburger on mobile screens */
@media (max-width: 900px) {
    .hamburger {
        display: block;
    }
    
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        border-radius: 0 0 8px 8px;
        padding: 1rem 0;
        z-index: 1000;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-links li {
        margin: 0;
    }
    
    .nav-links li a {
        display: block;
        padding: 0.75rem 1.5rem;
        color: var(--muted-800);
        text-decoration: none;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }
    
    .nav-links li a:hover {
        background-color: rgba(0, 0, 0, 0.05);
    }
    
    /* Dropdown adjustments for mobile */
    .dropdown .dropdown-content {
        position: static;
        display: none;
        box-shadow: none;
        background: rgba(0, 0, 0, 0.02);
        margin-left: 1rem;
    }
    
    .dropdown.open .dropdown-content {
        display: block;
    }
}

/* Prevent body scroll when mobile menu is open */
body.nav-open {
    overflow: hidden;
}

.calculator-container {
    width: 100%;
    max-width: 1200px;
    margin: 1.5rem auto;
    padding: 1.25rem;
    box-sizing: border-box;
    background: linear-gradient(180deg, rgba(255,255,255,0.95), rgba(250,250,252,0.95));
    border-radius: 14px;
    box-shadow: 0 8px 30px rgba(18, 25, 40, 0.08), inset 0 1px 0 rgba(255,255,255,0.6);
    transition: transform .18s ease, box-shadow .18s ease;
}

/* Sub-grid layout for inputs + results on larger screens */
.calculator-container .input-section,
.calculator-container .result-section {
    padding: 1rem;
    box-sizing: border-box;
}

/* Card look for inner areas */
.calculator-container .input-section {
    background: transparent;
}
.calculator-container .result-section {
    background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(240,245,255,0.02));
    border-radius: 10px;
    border: 1px solid rgba(18,25,40,0.04);
}

/* Two-column layout on wide screens */
@media (min-width: 920px) {
    .calculator-container {
        display: grid;
        grid-template-columns: 1fr 420px; /* main inputs | results */
        gap: 1.75rem;
        align-items: start;
    }
    .calculator-container .input-section {
        padding-right: 0.6rem;
    }
    .calculator-container .result-section {
        padding-left: 0.6rem;
    }
}

/* Stack vertically on small screens */
@media (max-width: 919px) {
    .calculator-container {
        display: block;
        padding: 1rem;
    }
    .calculator-container .result-section {
        margin-top: 1rem;
    }
}

/* Form controls styling */
.calculator-container input[type="number"],
.calculator-container input[type="text"],
.calculator-container select,
.calculator-container textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    border: 1px solid rgba(18,25,40,0.08);
    background: #fff;
    font-size: 0.95rem;
    color: #0f1724;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
    transition: border-color .12s ease, box-shadow .12s ease;
}
.calculator-container input:focus,
.calculator-container select:focus,
.calculator-container textarea:focus {
    outline: none;
    border-color: rgba(59,130,246,0.85);
    box-shadow: 0 4px 18px rgba(59,130,246,0.08);
}

/* Labels and titles */
.calculator-container .section-title {
    margin: 0 0 0.8rem 0;
    font-size: 1.1rem;
    color: #081126;
    font-weight: 600;
}

/* Buttons */
.calculator-container .btn-calc,
.calculator-container button {
    display: inline-block;
    padding: 0.6rem 0.9rem;
    border-radius: 10px;
    border: none;
    background: linear-gradient(180deg,#0ea5e9,#0284c7);
    color: #f5890e;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(2,132,199,0.12);
    transition: transform .12s ease, box-shadow .12s ease, opacity .12s ease;
}
.calculator-container .btn-calc:active { transform: translateY(1px); }
.calculator-container .btn-secondary {
    background: linear-gradient(180deg,#f3f4f6,#e6eef8);
    color: #0f1724;
    box-shadow: none;
    border: 1px solid rgba(18,25,40,0.05);
}

/* Results styling */
.calculator-container .results {
    padding: 1rem;
    border-radius: 8px;
}
.calculator-container .results p {
    margin: 0.45rem 0;
    font-size: 0.98rem;
    color: #0f1724;
}
.calculator-container .results strong {
    color: #0b63a6;
    font-size: 1.05rem;
}

/* Unit toggle buttons */
.calculator-container .unit-toggle {
    display:flex;
    gap:0.5rem;
    margin-bottom:0.8rem;
}
.calculator-container .unit-toggle button {
    background: transparent;
    border: 1px solid rgba(18,25,40,0.06);
    padding: 0.45rem 0.65rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight:600;
}
.calculator-container .unit-toggle button.active {
    background: linear-gradient(180deg,#0ea5e9,#0284c7);
    color:#fff;
    border-color: transparent;
    box-shadow: 0 6px 20px rgba(3,38,76,0.08);
}

/* Small helper */
.calculator-container .note { color: #6b7280; font-size: 0.9rem; }

/* Hover/interaction polish */
.calculator-container:hover { transform: translateY(-3px); }

/* Accessibility tweaks: focus-visible */
.calculator-container [tabindex]:focus-visible,
.calculator-container button:focus-visible,
.calculator-container input:focus-visible,
.calculator-container select:focus-visible {
    outline: 3px solid rgba(14,165,233,0.18);
    outline-offset: 2px;
}

.calculator-card h3 {
    margin-top: 1.2rem;
    color: #6b2c00;
}

.data-table-wrap {
    overflow-x: auto;
    margin: 0.8rem 0 1.2rem 0;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.data-table th,
.data-table td {
    padding: 0.65rem 0.9rem;
    text-align: left;
    border-bottom: 1px solid #f1f1f1;
    font-size: 0.98rem;
}

.data-table thead th {
    background: linear-gradient(90deg,#fff,#fff);
    color: #6b2c00;
    font-weight: 600;
}

.data-table tbody tr:nth-child(even) td {
    background: #fafafa;
}

.lead {
    font-size: 1rem;
    color: #333;
    line-height: 1.6;
    max-width: 900px;
    margin: 0.5rem auto 1rem auto;
}

/* Results section adjustments for dunk-height page */
.results {
    margin-top: 1rem;
    padding: 0.8rem;
}

#dh-touch, #dh-dunk {
    color: #6b2c00;
}

/* Responsive tweaks */
@media (max-width: 700px) {
    .input-row { gap: 0.6rem; flex-wrap: wrap; }
    .data-table th, .data-table td { padding: 0.55rem; font-size: 0.92rem; }
    .lead { padding: 0 0.6rem; }
}

/* Calculator card styling */
.calculator-card {
    background: linear-gradient(180deg, #ffffff 0%, #fff9f2 100%);
    border: 1px solid #f2e6dc;
    border-radius: 18px;
    padding: 1.25rem;
    box-shadow: 0 8px 24px rgba(107,44,0,0.08);
    max-width: 980px;
    margin: 1.2rem auto;
}

.calculator-card label {
    display: block;
    font-weight: 600;
    color: #6b2c00;
    margin-bottom: 0.35rem;
}

.calculator-card .input-row { gap: 1rem; align-items: center; }

.calculator-card input[type="number"],
.calculator-card select {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    border: 1px solid #eee;
    background: #fff;
}

.calculator-card .input-row .input-group { flex: 1 1 0; }

.calculator-card .input-row button {
    padding: 0.55rem 0.9rem;
    border-radius: 12px;
    border: none;
    background: #ff8800;
    color: #fff;
    cursor: pointer;
    font-weight: 700;
}

.calculator-card .input-row button#dh-reset { background: #f7f7f7; color: #6b2c00; border: 1px solid #eee; }

.calculator-card .results { background: transparent; text-align: left; }

/* Small screen adjustments */
@media (max-width: 700px) {
    .calculator-card { padding: 0.9rem; border-radius: 12px; }
    .calculator-card .input-row { flex-direction: column; gap: 0.6rem; }
}

.internal-links a,
.outbound-links a {
    color: #ff0707;
    text-decoration: underline;
    margin: 0 0.5rem;
    transition: color 0.2s;
}

.internal-links a:hover,
.outbound-links a:hover {
    color: #ff8800;
}

.faq {
    background: #fff;
    color: #222;
    border-radius: 24px;
    box-shadow: 0 4px 24px rgba(255, 136, 0, 0.12);
    padding: 2rem 1rem;
    max-width: 700px;
    margin: 2rem auto;
}

.faq h2 {
    color: #ff8800;
    font-size: 2rem;
    margin-bottom: 1rem;
}

.faq-item h3 {
    color: #6b2c00;
    font-size: 1.2rem;
    margin-bottom: 0.3rem;
}

.faq-item p {
    margin-bottom: 1.2rem;
}

footer {
    background: #ff8800;
    color: #fff;
    padding: 1.5rem 0 1rem 0;
    border-radius: 32px 32px 0 0;
    box-shadow: 0 -4px 24px rgba(107, 44, 0, 0.12);
    margin-top: 2rem;
}

.footer-content {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-links {
    margin-bottom: 1rem;
}

.footer-links a {
    color: #fff;
    text-decoration: underline;
    margin: 0 0.5rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #ff8800;
}

.footer-social a {
    color: #fff;
    font-size: 1.5rem;
    margin: 0 0.5rem;
    transition: color 0.2s;
}

.footer-social a:hover {
    color: #ff8800;
}

.footer-copy {
    margin-top: 1rem;
    font-size: 1rem;
}

@media (max-width: 600px) {
    .hero h1 {
        font-size: 2rem;
    }

    .calculator-container,
    .faq {
        padding: 1rem 0.5rem;
        max-width: 100%;
    }

    .result-section {
        padding: 1rem 0.5rem;
    }

    .footer-content {
        padding: 0 1rem;
    }
}

/* Ensure calculator content is left-aligned (override hero center for calculator areas) */
.calculator-container,
.calculator-card {
    text-align: left;
}

/* Labels inside calculators should be left aligned */
.calculator-container label,
.calculator-card label {
    text-align: left;
}

/* Make .input-row a flex container so feet / inches inputs sit on one row */
.input-row {
    display: flex;
    gap: 1rem;
    align-items: center;
}

/* Default .input-group inside an input-row should share space */
.input-row .input-group {
    flex: 1 1 0;
}

/* Ensure consistent spacing between input groups (horizontal gap) and vertical spacing */
.input-row > .input-group {
    margin-right: 0.75rem;   /* horizontal space between adjacent input-group blocks */
    margin-bottom: 0.6rem;  /* vertical space between stacked input-group blocks */
}

/* Remove extra right margin on the last group in a row */
.input-row > .input-group:last-child {
    margin-right: 0;
}

/* Slightly larger gap for close-feet/inches controls (nested rows) */
.input-row .input-row > .input-group {
    margin-right: 0.9rem;
}

/* Make sure individual inputs don't shrink too small so spacing looks balanced */
.input-row .input-group input,
.input-row .input-group select {
    min-width: 3.5rem;
}

/* Mobile: reduce horizontal margins so fields can wrap nicely */
@media (max-width: 700px) {
    .input-row > .input-group {
        margin-right: 0;
    }
    .input-row .input-row > .input-group {
        margin-right: 0;
    }
}

/* Enhanced styling for internal cards and page content — professional & eye-catching */

/* Card grid wrapper (internal links) */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    align-items: stretch;
}

/* Individual link cards inside internal-cards */
.internal-cards .calculator-card {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.15rem 1.15rem 1.15rem 1.35rem; /* extra left padding for accent */
    background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(245,252,255,0.96));
    border-radius: 14px;
    border: 1px solid rgba(3,38,76,0.06);
    box-shadow: 0 14px 40px rgba(6,24,51,0.08);
    transition: transform .22s cubic-bezier(.2,.9,.3,1), box-shadow .22s ease, border-color .18s ease;
    text-decoration: none;
    color: inherit;
    overflow: hidden;
}

/* vertical accent stripe on the left */
.internal-cards .calculator-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    background: linear-gradient(180deg, var(--primary-500), var(--accent-500));
    border-top-left-radius: 14px;
    border-bottom-left-radius: 14px;
}

/* small badge (optional) */
.internal-cards .calculator-card .card-badge {
    position: absolute;
    right: 12px;
    top: 12px;
    background: linear-gradient(90deg, rgba(14,165,233,0.12), rgba(255,122,89,0.12));
    color: var(--primary-700);
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.78rem;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(3,38,76,0.04);
}

/* card hover / focus */
.internal-cards .calculator-card:hover,
.internal-cards .calculator-card:focus {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 30px 70px rgba(6,24,51,0.14);
    border-color: rgba(3,38,76,0.12);
    z-index: 5;
}

/* Title and body inside card */
.internal-cards .calculator-card h4 {
    margin: 0;
    padding: 0;
    font-size: 1.05rem;
    color: var(--muted-900);
    font-weight: 800;
    letter-spacing: 0.2px;
}
.internal-cards .calculator-card p {
    margin: 0.45rem 0 0 0;
    color: var(--muted-600);
    font-size: 0.95rem;
}

/* subtle footer / CTA inside card */
.internal-cards .calculator-card .card-cta {
    margin-top: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--primary-700);
    font-weight: 700;
    text-decoration: none;
}
.internal-cards .calculator-card .card-cta svg { transform: translateY(1px); }

/* Page content (rich article) — stronger visual hierarchy */
.page-content .content-article {
    position: relative;
    background: linear-gradient(180deg,#ffffff, #fbfeff);
    border-radius: 16px;
    padding: 1.6rem;
    box-shadow: 0 30px 60px rgba(6,24,51,0.06);
    border: 1px solid rgba(3,38,76,0.04);
    overflow: hidden;
    transition: box-shadow .18s ease, transform .12s ease;
}

/* left accent stripe for article */
.page-content .content-article::before {
    content: "";
    position: absolute;
    left: -1px;
    top: 0;
    bottom: 0;
    width: 6px;
    background: linear-gradient(180deg, var(--primary-500), var(--accent-500));
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
}

/* Headings and lead */
.page-content .content-article h2 {
    margin-top: 0;
    color: var(--muted-900);
    font-size: 1.7rem;
    font-weight: 900;
    letter-spacing: 0.6px;
}
.page-content .content-article .lead,
.page-content .content-article p.lead {
    color: var(--muted-600);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 0.8rem;
}

/* Section headings */
.page-content .content-article h3 {
    color: var(--primary-700);
    margin-top: 1.1rem;
    font-size: 1.05rem;
    font-weight: 800;
}

/* paragraph and list body */
.page-content .content-article p,
.page-content .content-article li {
    color: var(--muted-600);
    line-height: 1.75;
    font-size: 0.99rem;
}

/* CTA row */
.page-content .content-article .cta-row {
    margin-top: 1rem;
    display:flex;
    gap:0.9rem;
    flex-wrap:wrap;
}
.page-content .content-article .btn-primary {
    display:inline-block;
    padding: 0.56rem 0.95rem;
    border-radius: 12px;
    background: linear-gradient(180deg,var(--primary-500),var(--primary-700));
    color: #fff;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 12px 28px rgba(3,38,76,0.09);
}

/* subtle divider between cards and content */
.internal-cards + .page-content {
    margin-top: 1rem;
}

/* Responsive adjustments */
@media (max-width: 920px) {
    .internal-cards .calculator-card { padding: 1rem; border-radius: 12px; }
    .page-content .content-article { padding: 1.05rem; border-radius: 12px; }
    .internal-cards .calculator-card::before,
    .page-content .content-article::before { display: none; }
}
@media (max-width: 520px) {
    .card-grid { gap: 0.75rem; }
    .page-content .content-article h2 { font-size: 1.35rem; }
}

/* Center the article card on the page but keep its inner text left-justified.
   Main heading (h2) stays centered. Paragraphs and lists are left-aligned
   with improved justification for cleaner reading. */
.page-content .content-article {
    margin-left: auto;
    margin-right: auto;
    max-width: 1000px;      /* limits line length for readability */
    text-align: left;       /* default for inner text */
}

.page-content .content-article h2 {
    text-align: center;     /* only the main heading is centered */
}

/* Section headings remain left-aligned */
.page-content .content-article h3 {
    text-align: left;
}

/* Paragraphs and list items: left aligned and lightly justified for nicer edge */
.page-content .content-article p,
.page-content .content-article li,
.page-content .content-article .lead {
    text-align: left;
    text-align-last: left;
    text-justify: inter-word;
    hyphens: auto;
}

/* Keep any small meta / badges right/left as originally designed */
.page-content .content-article .card-cta,
.page-content .content-article .cta-row {
    text-align: left;
}

/* Contact form styling — polished, responsive and consistent with site theme */
#contact-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.9rem;
    align-items: start;
    margin-top: 0.6rem;
}

/* Make the message textarea span full width */
#contact-form label {
    display: block;
    font-weight: 700;
    color: var(--muted-900);
    font-size: 0.95rem;
}

#contact-form input[type="text"],
#contact-form input[type="email"],
#contact-form input[type="tel"],
#contact-form input[type="url"],
#contact-form textarea {
    width: 100%;
    padding: 0.65rem 0.8rem;
    border-radius: 10px;
    border: 1px solid rgba(18,25,40,0.08);
    background: #fff;
    font-size: 0.95rem;
    color: #0f1724;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
    transition: border-color .12s ease, box-shadow .12s ease, transform .08s ease;
    resize: vertical;
}

/* Textarea taller and spanning both columns */
#contact-form textarea {
    min-height: 140px;
    grid-column: 1 / -1;
}

/* Inputs focus state */
#contact-form input:focus,
#contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-500);
    box-shadow: 0 6px 20px rgba(14,165,233,0.08);
}

/* Single-column fields that should span both columns (name/email/subject on small screens) */
#contact-form .full-width {
    grid-column: 1 / -1;
}

/* Form actions row */
#contact-form .form-actions {
    display: flex;
    gap: 0.8rem;
    align-items: center;
    grid-column: 1 / -1;
}

/* Primary button style (consistent with site) */
#contact-form .btn-primary {
    padding: 0.6rem 1rem;
    border-radius: 12px;
    border: none;
    background: linear-gradient(180deg,var(--primary-500),var(--primary-700));
    color: #fff;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 12px 28px rgba(3,38,76,0.08);
    transition: transform .12s ease, box-shadow .14s ease, opacity .12s ease;
}
#contact-form .btn-primary:active { transform: translateY(1px); }

/* Small helper text beside button */
#contact-form .form-note {
    color: var(--muted-600);
    font-size: 0.92rem;
}

/* Error / success message placeholders */
#contact-form .form-message {
    grid-column: 1 / -1;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    background: rgba(14,165,233,0.04);
    color: var(--muted-900);
    border: 1px solid rgba(14,165,233,0.08);
    display: none;
}

/* Accessibility: focus visible */
#contact-form input:focus-visible,
#contact-form textarea:focus-visible,
#contact-form .btn-primary:focus-visible {
    outline: 3px solid rgba(14,165,233,0.14);
    outline-offset: 2px;
}

/* Responsive: stack fields on small screens */
@media (max-width: 720px) {
    #contact-form {
        grid-template-columns: 1fr;
        gap: 0.7rem;
    }
    #contact-form textarea { min-height: 160px; }
    #contact-form .form-actions { justify-content: flex-start; }
}

/* Small visual polish for labels inside the contact page (.content-article) */
.page-content .content-article #contact-form label {
    margin-bottom: 0.25rem;
    color: var(--muted-800);
    font-weight: 700;
}