/* Dedicated one-off design for author/rahul.php - "The Route" theme, a
   COO profile page distinct from the generic author-profile-page.php
   template every other author uses. Own scoped tokens under .rg-page,
   same reasoning as every other page-family stylesheet in this repo:
   assumes only base-reset.css + vendored Font Awesome + the Fraunces/
   Plus Jakarta Sans Google Fonts load alongside it. */
:root {
    --navy-deep:  #081C30;
    --navy:       #0E2A47;
    --route-blue: #2B7FB3;
    --sky:        #4FC3E8;
    --amber:      #F0A63A;
    --amber-deep: #C77F1E;
    --coral:      #F0654E;
    --coral-deep: #D6472F;
    --teal:       #21B39A;
    --teal-deep:  #147F6C;
    --violet:     #8B6CF0;
    --cream:      #FAF6EF;
    --paper:      #FFFFFF;
    --charcoal:   #262524;
    --gray:       #6B7280;
    --gray-light: #9CA3AF;
    --border:     #E7E1D6;
    --success:    #4C8C6B;
    --shadow-sm:  0 2px 8px rgba(8,28,48,0.06);
    --shadow-md:  0 10px 30px rgba(8,28,48,0.10);
    --shadow-lg:  0 24px 60px rgba(8,28,48,0.16);
    --radius-sm:  10px;
    --radius-md:  16px;
    --radius-lg:  28px;
    --ease: cubic-bezier(.22,.61,.36,1);
    --grad-warm: linear-gradient(120deg, var(--coral) 0%, var(--amber) 100%);
    --grad-cool: linear-gradient(120deg, var(--route-blue) 0%, var(--teal) 100%);
    --grad-hero: radial-gradient(115% 140% at 12% -10%, #163A5C 0%, var(--navy) 38%, var(--navy-deep) 72%, #050F1B 100%),
                 radial-gradient(60% 60% at 92% 8%, rgba(33,179,154,.35) 0%, transparent 60%),
                 radial-gradient(50% 55% at 78% 95%, rgba(240,101,78,.28) 0%, transparent 65%);
}

.rg-page { background: var(--cream); color: var(--charcoal); font-family: 'Plus Jakarta Sans', -apple-system, sans-serif; overflow-x: hidden; }
.rg-page * { box-sizing: border-box; }
.rg-page h1, .rg-page h2, .rg-page h3, .rg-page h4 { font-family: 'Fraunces', Georgia, serif; color: var(--navy-deep); line-height: 1.15; margin: 0; }
.rg-wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.rg-section { padding: 88px 0; position: relative; }
@media (max-width: 768px) { .rg-section { padding: 56px 0; } }

.rg-eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
    color: var(--coral-deep); margin-bottom: 14px;
}
.rg-eyebrow::before { content: ''; width: 26px; height: 3px; background: var(--grad-warm); border-radius: 2px; }

.rg-lede { font-size: 19px; line-height: 1.75; color: #4B4A47; max-width: 62ch; }
.rg-lede strong { color: var(--navy-deep); }

.rg-reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.rg-reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) { .rg-reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- HERO ---------- */
.rg-hero {
    position: relative;
    background: var(--grad-hero);
    color: #fff; padding: 100px 0 130px; overflow: hidden;
}
.rg-hero::before {
    content: ''; position: absolute; inset: 0;
    background-image:
        repeating-linear-gradient(90deg, transparent, transparent 78px, rgba(255,255,255,.05) 78px, rgba(255,255,255,.05) 80px);
    opacity: .5; pointer-events: none;
}
.rg-hero-route {
    position: absolute; left: 0; right: 0; bottom: -1px; height: 90px;
    background: var(--cream);
    clip-path: polygon(0 100%, 0 40%, 6% 34%, 14% 44%, 22% 30%, 30% 40%, 38% 26%, 47% 38%, 56% 24%, 65% 36%, 74% 22%, 83% 34%, 91% 20%, 100% 32%, 100% 100%);
}
.rg-hero-grid { position: relative; display: grid; grid-template-columns: 300px 1fr; gap: 56px; align-items: center; z-index: 2; }
@media (max-width: 860px) { .rg-hero-grid { grid-template-columns: 1fr; text-align: center; gap: 32px; } }

.rg-hero-photo { position: relative; width: 260px; margin: 0 auto; }
.rg-hero-photo .ring {
    position: absolute; inset: -16px; border-radius: 50%;
    background: conic-gradient(from 0deg, var(--amber), var(--coral), var(--violet), var(--teal), var(--sky), var(--amber));
    animation: rg-spin 18s linear infinite;
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
    mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
    opacity: .9;
}
@media (prefers-reduced-motion: reduce) { .rg-hero-photo .ring { animation: none; } }
@keyframes rg-spin { to { transform: rotate(360deg); } }
.rg-hero-photo img {
    width: 260px; height: 260px; object-fit: cover; border-radius: 50%;
    border: 5px solid var(--paper); box-shadow: var(--shadow-lg); display: block; position: relative; z-index: 1;
}
.rg-hero-badge {
    position: absolute; bottom: 6px; right: 6px; z-index: 2;
    background: var(--grad-warm); color: #fff; font-weight: 800; font-size: 12px;
    padding: 7px 12px; border-radius: 999px; box-shadow: var(--shadow-md); white-space: nowrap;
}

.rg-hero-eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--amber); margin-bottom: 12px; }
.rg-hero h1 { font-size: clamp(38px, 5.4vw, 58px); font-weight: 700; color: #fff; margin-bottom: 6px; }
.rg-hero .role { font-size: clamp(17px, 2vw, 20px); color: #CFE0EE; font-weight: 500; margin-bottom: 18px; }
.rg-hero p.desc { color: #C7D2DC; font-size: 17px; line-height: 1.75; max-width: 54ch; margin-bottom: 30px; }
@media (max-width: 860px) { .rg-hero p.desc { margin-left: auto; margin-right: auto; } }

.rg-btn-row { display: flex; gap: 14px; flex-wrap: wrap; }
@media (max-width: 860px) { .rg-btn-row { justify-content: center; } }
.rg-btn {
    display: inline-flex; align-items: center; gap: 9px; padding: 14px 26px; border-radius: 999px;
    font-weight: 700; font-size: 15px; text-decoration: none; transition: transform .25s var(--ease), box-shadow .25s var(--ease);
    border: 2px solid transparent;
}
.rg-btn:hover { transform: translateY(-3px); }
.rg-btn-primary { background: var(--grad-warm); color: #fff; box-shadow: 0 10px 26px rgba(240,101,78,.35); }
.rg-btn-primary:hover { box-shadow: 0 14px 34px rgba(240,101,78,.5); }
.rg-btn-ghost { border-color: rgba(255,255,255,.35); color: #fff; }
.rg-btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,.1); }
.rg-btn-cool { background: var(--grad-cool); color: #fff; box-shadow: 0 10px 26px rgba(33,179,154,.35); }
.rg-btn-cool:hover { box-shadow: 0 14px 34px rgba(33,179,154,.5); }

/* ---------- TRUST STRIP ---------- */
.rg-stats {
    max-width: 1000px; margin: -64px auto 0; position: relative; z-index: 3;
    background: var(--paper); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
    display: grid; grid-template-columns: repeat(4, 1fr); padding: 34px 10px;
    border-top: 4px solid transparent;
    border-image: linear-gradient(90deg, var(--coral), var(--amber), var(--teal), var(--route-blue)) 1;
}
.rg-stat:nth-child(1) .num { color: var(--coral-deep); }
.rg-stat:nth-child(2) .num { color: var(--amber-deep); }
.rg-stat:nth-child(3) .num { color: var(--teal-deep); }
.rg-stat:nth-child(4) .num { color: var(--route-blue); }
@media (max-width: 720px) { .rg-stats { grid-template-columns: repeat(2, 1fr); row-gap: 26px; margin-top: -46px; border-radius: var(--radius-md); } }
.rg-stat { text-align: center; padding: 0 12px; border-right: 1px solid var(--border); }
.rg-stat:last-child { border-right: none; }
@media (max-width: 720px) { .rg-stat:nth-child(2n) { border-right: none; } .rg-stat:nth-child(-n+2) { border-bottom: 1px solid var(--border); padding-bottom: 20px; } }
.rg-stat .num { font-family: 'Fraunces', serif; font-size: 34px; font-weight: 700; }
.rg-stat .lbl { font-size: 13px; color: var(--gray); font-weight: 600; margin-top: 4px; }

/* ---------- ABOUT ---------- */
.rg-about-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 64px; align-items: start; }
@media (max-width: 860px) { .rg-about-grid { grid-template-columns: 1fr; gap: 36px; } }
.rg-about-grid h2 { font-size: clamp(28px, 3.4vw, 38px); margin-bottom: 22px; }
.rg-about-grid p { color: #4B4A47; font-size: 16.5px; line-height: 1.85; margin-bottom: 16px; }
.rg-pull {
    border-left: 4px solid var(--amber); padding: 4px 0 4px 22px; margin: 26px 0;
    font-family: 'Fraunces', serif; font-size: 20px; font-style: italic; color: var(--navy);
}
.rg-value-list { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 14px; }
.rg-value-list li { display: flex; gap: 14px; align-items: flex-start; font-size: 15.5px; color: #4B4A47; }
.rg-value-list .ico {
    flex: none; width: 34px; height: 34px; border-radius: 10px; background: rgba(43,127,179,.1);
    color: var(--route-blue); display: flex; align-items: center; justify-content: center; font-size: 15px;
}

.rg-about-card {
    background: var(--paper); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}
.rg-about-card h3 { font-size: 19px; margin-bottom: 18px; }
.rg-fact { display: flex; justify-content: space-between; align-items: center; padding: 13px 0; border-bottom: 1px solid var(--border); font-size: 15px; }
.rg-fact:last-of-type { border-bottom: none; }
.rg-fact .k { color: var(--gray); font-weight: 600; }
.rg-fact .v { color: var(--navy-deep); font-weight: 700; text-align: right; }
.rg-social-row { display: flex; gap: 10px; margin-top: 22px; }
.rg-social-row a {
    width: 42px; height: 42px; border-radius: 50%; background: var(--navy); color: #fff;
    display: flex; align-items: center; justify-content: center; text-decoration: none; transition: background .2s var(--ease), transform .2s var(--ease);
}
.rg-social-row a:hover { background: var(--route-blue); transform: translateY(-3px); }

/* ---------- GALLERY ---------- */
.rg-gallery-head { text-align: center; max-width: 640px; margin: 0 auto 44px; }
.rg-gallery-head .rg-eyebrow { justify-content: center; }
.rg-gallery-label {
    font-size: 12.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
    color: var(--gray); margin: 0 0 16px;
}
.rg-gallery-label:not(:first-child) { margin-top: 40px; }

.rg-figure {
    margin: 0; position: relative; border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-sm);
    transition: box-shadow .3s var(--ease);
}
.rg-figure::after {
    content: ''; position: absolute; inset: 0; border-radius: var(--radius-md);
    box-shadow: inset 0 0 0 3px transparent; transition: box-shadow .3s var(--ease); pointer-events: none;
}
.rg-figure:hover::after { box-shadow: inset 0 0 0 3px var(--tile-accent, var(--amber)); }
.rg-figure img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s var(--ease); filter: saturate(1.02); }
.rg-figure:hover img { transform: scale(1.06); }
.rg-figure figcaption {
    position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 14px 12px;
    background: linear-gradient(0deg, rgba(8,28,48,.86) 0%, rgba(8,28,48,0) 100%);
    color: #fff; font-size: 13px; font-weight: 700; opacity: 0; transform: translateY(8px);
    transition: opacity .3s var(--ease), transform .3s var(--ease);
    display: flex; align-items: center; gap: 7px;
}
.rg-figure figcaption::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--tile-accent, var(--amber)); flex: none; }
.rg-figure:hover figcaption { opacity: 1; transform: translateY(0); }

.rg-land-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.rg-land-grid .rg-figure { aspect-ratio: 16 / 9; }
.rg-land-hero { grid-column: span 6; }
.rg-land-half { grid-column: span 3; }
@media (max-width: 700px) {
    .rg-land-grid { grid-template-columns: 1fr; }
    .rg-land-hero, .rg-land-half { grid-column: span 1; }
}

.accent-coral  { --tile-accent: var(--coral); }
.accent-amber  { --tile-accent: var(--amber); }
.accent-teal   { --tile-accent: var(--teal); }
.accent-blue   { --tile-accent: var(--route-blue); }
.accent-violet { --tile-accent: var(--violet); }

.rg-port-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.rg-port-grid .rg-figure { aspect-ratio: 3 / 4; }
.rg-port-lg { grid-column: span 3; }
.rg-port-sm { grid-column: span 2; }
@media (max-width: 700px) {
    .rg-port-grid { grid-template-columns: repeat(2, 1fr); }
    .rg-port-lg { grid-column: span 2; }
    .rg-port-sm { grid-column: span 1; }
}

/* ---------- TIMELINE ---------- */
.rg-timeline-section { background: var(--paper); }
.rg-route {
    position: relative; max-width: 780px; margin: 60px auto 0; padding-left: 46px;
}
.rg-route::before {
    content: ''; position: absolute; left: 14px; top: 6px; bottom: 6px; width: 3px;
    background: linear-gradient(180deg, var(--coral), var(--amber) 32%, var(--teal) 64%, var(--route-blue) 100%);
    -webkit-mask: repeating-linear-gradient(180deg, #000 0 10px, transparent 10px 18px);
    mask: repeating-linear-gradient(180deg, #000 0 10px, transparent 10px 18px);
    border-radius: 3px;
}
.rg-stop { position: relative; padding-bottom: 46px; --stop-accent: var(--route-blue); }
.rg-stop:last-child { padding-bottom: 0; }
.rg-stop:nth-child(1) { --stop-accent: var(--coral); }
.rg-stop:nth-child(2) { --stop-accent: var(--amber); }
.rg-stop:nth-child(3) { --stop-accent: var(--teal); }
.rg-stop:nth-child(4) { --stop-accent: var(--route-blue); }
.rg-stop:nth-child(5) { --stop-accent: var(--violet); }
.rg-stop:nth-child(6) { --stop-accent: var(--teal-deep); }
.rg-stop::before {
    content: ''; position: absolute; left: -46px; top: 2px; width: 32px; height: 32px; border-radius: 50%;
    background: var(--paper); border: 3px solid var(--stop-accent); z-index: 2; box-shadow: 0 0 0 4px var(--paper);
}
.rg-stop.is-current::before { border-color: var(--coral); background: var(--grad-warm); }
.rg-stop-icon {
    position: absolute; left: -40px; top: 8px; width: 20px; height: 20px; z-index: 3;
    color: var(--stop-accent); font-size: 12px; display: flex; align-items: center; justify-content: center;
}
.rg-stop.is-current .rg-stop-icon { color: #fff; }
.rg-stop-card {
    background: var(--cream); border: 1px solid var(--border); border-radius: var(--radius-md);
    padding: 22px 24px; transition: transform .3s var(--ease), box-shadow .3s var(--ease);
    border-left: 3px solid var(--stop-accent);
}
.rg-stop-card:hover { transform: translateX(6px); box-shadow: var(--shadow-md); }
.rg-stop.is-current .rg-stop-card { background: linear-gradient(135deg, rgba(240,101,78,.12), rgba(240,166,58,.06)); border-color: rgba(240,101,78,.4); border-left-color: var(--coral); }
.rg-stop-date { font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--stop-accent); }
.rg-stop-card h4 { font-size: 19px; margin: 6px 0 3px; }
.rg-stop-org { font-size: 14.5px; color: var(--gray); font-weight: 600; margin-bottom: 10px; }
.rg-stop-card p { font-size: 14.5px; color: #4B4A47; line-height: 1.65; margin: 0; }
.rg-stop-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.rg-stop-tags span { font-size: 12px; font-weight: 600; background: color-mix(in srgb, var(--stop-accent) 14%, transparent); color: var(--stop-accent); padding: 5px 11px; border-radius: 999px; }

/* ---------- SKILLS ---------- */
.rg-skills-wrap { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.rg-skill-pill {
    display: inline-flex; align-items: center; gap: 9px; background: var(--paper); border: 1px solid var(--border);
    padding: 12px 20px; border-radius: 999px; font-weight: 600; font-size: 14.5px; color: var(--navy-deep);
    box-shadow: var(--shadow-sm); transition: border-color .2s var(--ease), transform .2s var(--ease);
}
.rg-skill-pill:hover { border-color: var(--pill-accent, var(--route-blue)); transform: translateY(-3px); box-shadow: var(--shadow-md); }
.rg-skill-pill i { color: var(--pill-accent, var(--route-blue)); }
.rg-skills-wrap .rg-skill-pill:nth-child(1) { --pill-accent: var(--coral); }
.rg-skills-wrap .rg-skill-pill:nth-child(2) { --pill-accent: var(--amber-deep); }
.rg-skills-wrap .rg-skill-pill:nth-child(3) { --pill-accent: var(--teal-deep); }
.rg-skills-wrap .rg-skill-pill:nth-child(4) { --pill-accent: var(--route-blue); }
.rg-skills-wrap .rg-skill-pill:nth-child(5) { --pill-accent: var(--violet); }
.rg-skills-wrap .rg-skill-pill:nth-child(6) { --pill-accent: var(--coral-deep); }

/* ---------- ARTICLES ---------- */
.rg-articles-section { background: var(--cream); }
.rg-article-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; margin-top: 40px; }
@media (max-width: 900px) { .rg-article-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .rg-article-grid { grid-template-columns: 1fr; } }
.rg-card {
    background: var(--paper); border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-sm);
    border: 1px solid var(--border); display: flex; flex-direction: column; position: relative;
    transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.rg-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px; z-index: 2;
    background: linear-gradient(90deg, var(--coral), var(--amber), var(--teal), var(--route-blue));
    transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease);
}
.rg-card:hover::before { transform: scaleX(1); }
.rg-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.rg-card-img { aspect-ratio: 16/10; overflow: hidden; }
.rg-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.rg-card:hover .rg-card-img img { transform: scale(1.06); }
.rg-card-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.rg-card-meta { font-size: 12.5px; font-weight: 700; color: var(--teal-deep); display: flex; align-items: center; gap: 7px; margin-bottom: 10px; }
.rg-card-body h3 { font-size: 18px; margin-bottom: 8px; line-height: 1.4; }
.rg-card-body h3 a { color: var(--navy-deep); text-decoration: none; }
.rg-card-body h3 a:hover { color: var(--route-blue); }
.rg-card-body p { font-size: 14.5px; color: var(--gray); line-height: 1.6; flex: 1; margin: 0 0 16px; }
.rg-read-more { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; color: var(--coral-deep); text-decoration: none; }
.rg-read-more i { transition: transform .25s var(--ease); }
.rg-read-more:hover i { transform: translateX(4px); }

.rg-pagination { display: flex; justify-content: center; gap: 10px; margin-top: 52px; flex-wrap: wrap; }
.rg-pagination a {
    min-width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; padding: 0 6px;
    border: 1px solid var(--border); border-radius: 12px; background: var(--paper);
    color: var(--navy); font-weight: 700; text-decoration: none; transition: all .2s var(--ease);
}
.rg-pagination a:hover { border-color: var(--route-blue); color: var(--route-blue); }
.rg-pagination a.active { background: var(--grad-cool); color: #fff; border-color: transparent; }

/* ---------- CTA ---------- */
.rg-cta-band {
    background: linear-gradient(120deg, var(--navy-deep), var(--navy)); border-radius: var(--radius-lg);
    padding: 56px; text-align: center; color: #fff; position: relative; overflow: hidden;
}
.rg-cta-band::before {
    content: ''; position: absolute; inset: 0; border-radius: var(--radius-lg); padding: 2px;
    background: linear-gradient(120deg, var(--coral), var(--amber), var(--teal), var(--route-blue));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude;
    opacity: .8; pointer-events: none;
}
.rg-cta-band::after {
    content: ''; position: absolute; width: 340px; height: 340px; border-radius: 50%;
    background: radial-gradient(circle, rgba(240,101,78,.3), transparent 70%);
    top: -140px; right: -100px;
}
.rg-cta-band .glow-2 {
    content: ''; position: absolute; width: 300px; height: 300px; border-radius: 50%;
    background: radial-gradient(circle, rgba(33,179,154,.28), transparent 70%);
    bottom: -140px; left: -80px; pointer-events: none;
}
.rg-cta-band h2 { color: #fff; font-size: clamp(24px, 3vw, 32px); margin-bottom: 12px; position: relative; }
.rg-cta-band p { color: #C7D2DC; font-size: 16px; margin-bottom: 26px; position: relative; }
.rg-cta-band .rg-btn-row { justify-content: center; position: relative; }

.rg-empty { text-align: center; padding: 60px 20px; color: var(--gray); grid-column: 1 / -1; }
