/*
 * EarnGiftHub Tools - site design (1.1.0)
 * Part 1: colours and shared pieces (buttons, cards, grids) used by every egh- block.
 * Part 2: gentle polish for the Astra theme, only under body.egh-site.
 * No outside fonts, images or files. Nothing from other plugins is styled or hidden.
 */

:root{
	--egh-primary:#4f46e5;
	--egh-primary-dark:#3730a3;
	--egh-violet:#7c3aed;
	--egh-ink:#1e1b4b;
	--egh-text:#27272f;
	--egh-muted:#5b6170;
	--egh-bg:#f7f6fb;
	--egh-card:#ffffff;
	--egh-line:#e6e3f3;
	--egh-tint:#eef0ff;
	--egh-gold:#f5b301;
	--egh-gold-light:#ffd95a;
	--egh-gold-dark:#8a4b06;
	--egh-gold-soft:#fff6d6;
	--egh-ok:#15803d;
	--egh-err:#b91c1c;
	--egh-radius:16px;
	--egh-radius-sm:12px;
	--egh-shadow:0 1px 2px rgba(30,27,75,.06),0 8px 24px rgba(30,27,75,.07);
	--egh-shadow-lg:0 2px 4px rgba(30,27,75,.08),0 16px 40px rgba(30,27,75,.14);
	--egh-font:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif;
}

/* ---------- Shared pieces ---------- */

.egh-wide,.egh-wide *,.egh-wide *::before,.egh-wide *::after{box-sizing:border-box}
.egh-wide{width:100%;max-width:1120px;margin:0 auto 1.5rem;color:var(--egh-text);font-family:var(--egh-font);font-size:16px;line-height:1.55;overflow-wrap:break-word}
.egh-ico{display:inline-block;flex:0 0 auto;width:24px;height:24px;vertical-align:middle}
.egh-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}

/* Buttons */
:is(.egh-wide,.egh-box) .egh-btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;max-width:100%;padding:11px 22px;border:2px solid transparent;border-radius:999px;background:var(--egh-primary);color:#fff;font-family:var(--egh-font);font-size:16px;font-weight:700;line-height:1.3;letter-spacing:0;text-transform:none;text-decoration:none;text-align:center;box-shadow:0 1px 2px rgba(30,27,75,.18);cursor:pointer;touch-action:manipulation;transition:background-color .15s ease,color .15s ease,border-color .15s ease,transform .1s ease}
:is(.egh-wide,.egh-box) .egh-btn:hover,:is(.egh-wide,.egh-box) .egh-btn:focus{background:var(--egh-primary-dark);color:#fff;border-color:transparent;text-decoration:none}
:is(.egh-wide,.egh-box) .egh-btn:active{transform:translateY(1px)}
:is(.egh-wide,.egh-box) .egh-btn:focus-visible{outline:3px solid #a5b4fc;outline-offset:2px}
:is(.egh-wide,.egh-box) .egh-btn:disabled,:is(.egh-wide,.egh-box) .egh-btn[disabled]{opacity:.5;cursor:not-allowed;transform:none}
:is(.egh-wide,.egh-box) .egh-btn-alt{background:var(--egh-tint);color:var(--egh-primary-dark);box-shadow:none}
:is(.egh-wide,.egh-box) .egh-btn-alt:hover,:is(.egh-wide,.egh-box) .egh-btn-alt:focus{background:#dfe2ff;color:var(--egh-ink)}
:is(.egh-wide,.egh-box) .egh-btn-gold{background:var(--egh-gold);color:#2a1a00}
:is(.egh-wide,.egh-box) .egh-btn-gold:hover,:is(.egh-wide,.egh-box) .egh-btn-gold:focus{background:var(--egh-gold-light);color:#2a1a00}
:is(.egh-wide,.egh-box) .egh-btn-ghost{background:rgba(255,255,255,.12);color:#fff;border-color:rgba(255,255,255,.7);box-shadow:none}
:is(.egh-wide,.egh-box) .egh-btn-ghost:hover,:is(.egh-wide,.egh-box) .egh-btn-ghost:focus{background:#fff;color:var(--egh-primary-dark);border-color:#fff}
:is(.egh-wide,.egh-box) .egh-btn-dark{background:var(--egh-ink);color:#fff}
:is(.egh-wide,.egh-box) .egh-btn-dark:hover,:is(.egh-wide,.egh-box) .egh-btn-dark:focus{background:#000;color:#fff}
:is(.egh-wide,.egh-box) .egh-btn-light{background:rgba(255,255,255,.75);color:var(--egh-ink);border-color:rgba(30,27,75,.25);box-shadow:none}
:is(.egh-wide,.egh-box) .egh-btn-light:hover,:is(.egh-wide,.egh-box) .egh-btn-light:focus{background:#fff;color:var(--egh-ink);border-color:var(--egh-ink)}

/* Sections and grids */
.egh-section{margin:44px 0 0}
.egh-wide .egh-section .egh-section-title{margin:0 0 18px;color:var(--egh-ink);font-family:var(--egh-font);font-size:1.35rem;font-size:clamp(1.35rem,1.1rem + 1.2vw,1.75rem);font-weight:800;line-height:1.2;text-align:center}
.egh-grid{display:grid;gap:18px;grid-template-columns:minmax(0,1fr)}
@media (min-width:480px){
	.egh-grid-5{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (min-width:600px){
	.egh-grid-3,.egh-grid-4{grid-template-columns:repeat(2,minmax(0,1fr))}
	.egh-grid-5{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media (min-width:960px){
	.egh-grid-3{grid-template-columns:repeat(3,minmax(0,1fr))}
	.egh-grid-4{grid-template-columns:repeat(4,minmax(0,1fr))}
	.egh-grid-5{grid-template-columns:repeat(5,minmax(0,1fr))}
}

/* Cards */
.egh-card{display:flex;flex-direction:column;align-items:flex-start;gap:8px;min-width:0;padding:22px;border:1px solid var(--egh-line);border-radius:var(--egh-radius);background:var(--egh-card);color:var(--egh-text);box-shadow:var(--egh-shadow)}
.egh-wide a.egh-card-link{color:var(--egh-text);text-decoration:none;transition:transform .15s ease,box-shadow .15s ease,border-color .15s ease}
.egh-wide a.egh-card-link:hover,.egh-wide a.egh-card-link:focus{color:var(--egh-text);text-decoration:none;transform:translateY(-3px);border-color:#c7c2f2;box-shadow:var(--egh-shadow-lg)}
.egh-wide a.egh-card-link:focus-visible{outline:3px solid #a5b4fc;outline-offset:2px}
.egh-card-ico{display:inline-flex;align-items:center;justify-content:center;width:48px;height:48px;border-radius:14px;background:var(--egh-tint);color:var(--egh-primary)}
.egh-grid>.egh-card:nth-child(3n+3) .egh-card-ico{background:var(--egh-gold-soft);color:var(--egh-gold-dark)}
.egh-wide .egh-card-title{display:block;margin:4px 0 0;padding:0;color:var(--egh-ink);font-family:var(--egh-font);font-size:1.15rem;font-weight:800;line-height:1.25}
.egh-wide .egh-card-text{display:block;margin:0;color:var(--egh-muted);font-size:.97rem;line-height:1.5}
.egh-card-go{white-space:nowrap;display:inline-flex;align-items:center;gap:6px;min-height:28px;margin-top:auto;padding-top:8px;color:var(--egh-primary);font-weight:700}
.egh-card-go .egh-ico{width:18px;height:18px;transition:transform .15s ease}
.egh-card-link:hover .egh-card-go .egh-ico{transform:translateX(3px)}

/* Hero (home) and join card (earn, logged out) */
.egh-hero,.egh-join{position:relative;overflow:hidden;padding:28px 20px;padding:clamp(28px,6vw,64px) clamp(20px,5vw,56px);border-radius:24px;background:linear-gradient(135deg,#3730a3 0%,#4f46e5 48%,#7c3aed 100%);color:#fff;box-shadow:var(--egh-shadow-lg)}
.egh-hero>*,.egh-join>*{position:relative;z-index:1}
.egh-hero .egh-hero-coins{position:absolute;z-index:0;inset:0;pointer-events:none}
.egh-hero-coins span{position:absolute;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffe58a 0%,#f5b301 55%,#c98a00 100%);box-shadow:inset 0 0 0 6px rgba(255,255,255,.22);opacity:.9}
.egh-hero-coins span:nth-child(1){width:150px;height:150px;right:-34px;top:-40px}
.egh-hero-coins span:nth-child(2){width:74px;height:74px;right:120px;bottom:-22px;opacity:.75}
.egh-hero-coins span:nth-child(3){width:40px;height:40px;right:44px;top:150px;opacity:.6}
.egh-wide .egh-eyebrow{display:inline-block;margin:0 0 14px;padding:6px 14px;border-radius:999px;background:rgba(255,255,255,.16);color:#fff;font-size:.85rem;font-weight:700;letter-spacing:.02em}
.egh-wide .egh-hero .egh-hero-title{max-width:17em;margin:0 0 14px;padding:0;color:#fff;font-family:var(--egh-font);font-size:1.75rem;font-size:clamp(1.75rem,1.1rem + 3.4vw,3.1rem);font-weight:800;line-height:1.12;letter-spacing:-.01em}
.egh-wide .egh-hero-sub{max-width:36em;margin:0 0 22px;color:#e6e4ff;font-size:1rem;font-size:clamp(1rem,.95rem + .35vw,1.15rem);line-height:1.55}
.egh-wide .egh-hero-actions{display:flex;flex-wrap:wrap;gap:12px;margin:0 0 20px}
.egh-wide .egh-hero-points{display:flex;flex-wrap:wrap;gap:8px 20px;margin:0;padding:0;list-style:none;color:#e6e4ff;font-size:.95rem;font-weight:600}
.egh-wide .egh-hero-points li{position:relative;margin:0;padding:0 0 0 22px;list-style:none}
.egh-hero-points li::before{content:"";position:absolute;left:0;top:.38em;width:14px;height:14px;border-radius:50%;background:var(--egh-gold);box-shadow:inset 0 0 0 3px rgba(255,255,255,.35)}
.egh-join{margin:0 0 22px}
.egh-wide .egh-join .egh-join-title{margin:0 0 10px;padding:0;color:#fff;font-family:var(--egh-font);font-size:1.4rem;font-size:clamp(1.4rem,1.1rem + 1.8vw,2.1rem);font-weight:800;line-height:1.18}
.egh-wide .egh-join-text{max-width:38em;margin:0 0 20px;color:#e6e4ff;font-size:1.05rem}
.egh-join .egh-hero-actions{margin-bottom:0}

/* How coins work */
.egh-wide .egh-steps{display:grid;gap:18px;grid-template-columns:minmax(0,1fr);margin:0;padding:0;list-style:none;counter-reset:none}
.egh-wide .egh-step{display:flex;flex-direction:column;gap:6px;margin:0;padding:22px;border:1px dashed #cfc9f5;border-radius:var(--egh-radius);background:var(--egh-tint);list-style:none}
.egh-step-num{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;margin-bottom:4px;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffe58a 0%,#f5b301 60%,#d99a00 100%);color:#3b2300;font-weight:800;font-size:1.1rem;box-shadow:inset 0 0 0 3px rgba(255,255,255,.4)}
.egh-step-title{color:var(--egh-ink);font-size:1.08rem;font-weight:800;line-height:1.3}
.egh-step-text{color:var(--egh-muted);font-size:.97rem}

@media (min-width:800px){
	.egh-wide .egh-steps{grid-template-columns:repeat(3,minmax(0,1fr))}
}

/* Giveaway banner */
.egh-banner{display:flex;flex-wrap:wrap;align-items:center;gap:16px 20px;margin:44px 0 0;padding:20px;padding:clamp(20px,4vw,32px);border-radius:24px;background:linear-gradient(135deg,#ffe58a 0%,#f8c21b 60%,#f5a301 100%);color:#2a1a00;box-shadow:var(--egh-shadow)}
.egh-banner-ico{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;width:56px;height:56px;border-radius:50%;background:rgba(255,255,255,.55);color:#5a3200}
.egh-banner-ico .egh-ico{width:30px;height:30px}
.egh-banner-body{flex:1 1 260px;min-width:0}
.egh-wide .egh-banner .egh-banner-title{margin:0 0 4px;padding:0;color:#2a1a00;font-family:var(--egh-font);font-size:1.15rem;font-size:clamp(1.15rem,1rem + 1vw,1.55rem);font-weight:800;line-height:1.25}
.egh-wide .egh-banner-text{margin:0;color:#4a2e00;font-size:1rem}

/* Notices and small print */
.egh-wide .egh-notice{display:flex;align-items:center;gap:12px;margin:0 0 20px;padding:14px 18px;border:1px solid #f1dc8f;border-radius:var(--egh-radius-sm);background:var(--egh-gold-soft);color:#5a3a00;font-size:1rem;font-weight:600;line-height:1.45}
.egh-notice .egh-ico{color:var(--egh-gold-dark)}
.egh-wide .egh-notice-row{flex-wrap:wrap;justify-content:space-between;margin:22px 0 0}
.egh-notice-row>span{display:inline-flex;align-items:center;gap:12px;flex:1 1 240px;min-width:0}
.egh-wide .egh-fineprint{margin:14px 0 0;color:var(--egh-muted);font-size:.85rem;text-align:center}
.egh-registered-note{box-sizing:border-box;max-width:760px;margin:0 auto 18px;padding:14px 18px;border:1px solid #b7e4c7;border-radius:var(--egh-radius-sm);background:#ecfdf5;color:#065f46;font-family:var(--egh-font);font-size:1rem;font-weight:600;line-height:1.45}

/* Stores (coupons) and gift cards: plain coloured text tiles, no logos */
.egh-tone-1{background:linear-gradient(135deg,#f97316,#ea580c)}
.egh-tone-2{background:linear-gradient(135deg,#0ea5a4,#0f766e)}
.egh-tone-3{background:linear-gradient(135deg,#2563eb,#1e40af)}
.egh-tone-4{background:linear-gradient(135deg,#475569,#1e293b)}
.egh-tone-5{background:linear-gradient(135deg,#7c3aed,#4f46e5)}
.egh-store{align-items:stretch}
.egh-store-badge{display:inline-flex;align-items:center;justify-content:center;width:52px;height:52px;border-radius:14px;color:#fff;font-size:1.5rem;font-weight:800}
.egh-store .egh-btn,.egh-gc .egh-btn{width:100%;margin-top:auto}
.egh-store .egh-card-text{margin-bottom:8px}
.egh-gc{align-items:stretch;gap:14px;padding:14px}
.egh-gc-tile{display:flex;flex-direction:column;justify-content:flex-end;gap:2px;min-height:118px;padding:16px;border-radius:var(--egh-radius-sm);color:#fff}
.egh-gc-name{font-size:1.2rem;font-weight:800;line-height:1.2}
.egh-gc-kind{font-size:.82rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;opacity:.9}
.egh-gc .egh-btn{padding-left:12px;padding-right:12px;font-size:.95rem}

/* Earn page layout */
.egh-earn-top{margin:0 0 20px}
.egh-earn-grid{display:grid;gap:20px;align-items:start;grid-template-columns:minmax(0,1fr)}
@media (min-width:860px){
	.egh-earn-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
.egh-earn .egh-box{max-width:none;margin:0}

/* Account pill in the menu */
.egh-pill{display:inline-flex;align-items:center;gap:7px;min-height:36px;padding:6px 14px;border-radius:999px;background:var(--egh-gold-soft);color:#5a3a00;border:1px solid #f1dc8f;font-weight:800;line-height:1.2;white-space:nowrap}
.egh-pill-coin{display:inline-block;flex:0 0 auto;width:18px;height:18px;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffe58a 0%,#f5b301 60%,#c98a00 100%);box-shadow:inset 0 0 0 2px rgba(255,255,255,.5),0 0 0 1px #c98a00}
.egh-pill-cta{background:var(--egh-primary);color:#fff;border-color:var(--egh-primary)}
a:hover>.egh-pill-cta,a:focus>.egh-pill-cta{background:var(--egh-primary-dark);border-color:var(--egh-primary-dark);color:#fff}
a:hover>.egh-pill:not(.egh-pill-cta),a:focus>.egh-pill:not(.egh-pill-cta){background:#ffeeb0}

@media (max-width:544px){
	.egh-wide .egh-hero-actions .egh-btn{flex:1 1 100%}
	.egh-hero-coins span:nth-child(1){width:104px;height:104px;right:-40px;top:-44px;opacity:.55}
	.egh-hero-coins span:nth-child(2),.egh-hero-coins span:nth-child(3){display:none}
	.egh-banner .egh-btn,.egh-notice-row .egh-btn{width:100%}
	.egh-card{padding:18px}
	.egh-section{margin-top:34px}
	.egh-banner{margin-top:34px}
}
@media (prefers-reduced-motion:reduce){
	.egh-wide *,.egh-box *{transition:none !important}
}

/* ---------- Astra theme polish (only while this plugin is active) ---------- */

body.egh-site{
	--ast-global-color-0:#4f46e5;
	--ast-global-color-1:#3730a3;
	--ast-global-color-2:#1e1b4b;
	--ast-global-color-3:#27272f;
	--ast-global-color-4:#ffffff;
	--ast-global-color-5:#f1f0fa;
	--ast-global-color-7:#e6e3f3;
	background-color:var(--egh-bg);
	color:var(--egh-text);
	font-family:var(--egh-font);
	-webkit-text-size-adjust:100%;
	overflow-x:hidden;
}
body.egh-site #page{overflow-x:clip}
body.egh-site :is(h1,h2,h3,h4,h5,h6,.entry-title,.site-title){font-family:var(--egh-font);color:var(--egh-ink)}
body.egh-site :is(.entry-content,.ast-footer-copyright,.main-header-menu,button,input,select,textarea){font-family:var(--egh-font)}
body.egh-site #content{background:transparent}

/* Header */
body.egh-site .site-header{position:relative;z-index:20}
body.egh-site :is(.ast-primary-header-bar,.main-header-bar){background:#fff;border-bottom:1px solid var(--egh-line);box-shadow:0 1px 10px rgba(30,27,75,.05)}
body.egh-site .site-title{font-size:1.4rem;font-weight:800;letter-spacing:-.01em;line-height:1.2}
body.egh-site .site-title a{display:inline-flex;align-items:center;gap:10px;min-height:44px;color:var(--egh-ink);text-decoration:none}
body.egh-site .site-title a:hover,body.egh-site .site-title a:focus{color:var(--egh-primary)}
body.egh-site .site-title a::before{content:"";flex:0 0 auto;width:28px;height:28px;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffe58a 0%,#f5b301 58%,#c98a00 100%);box-shadow:inset 0 0 0 3px rgba(255,255,255,.5),0 0 0 2px #c98a00}
body.egh-site .main-header-menu>.menu-item>.menu-link{min-height:44px;color:var(--egh-text);font-weight:600;text-decoration:none}
body.egh-site .main-header-menu>.menu-item>.menu-link:hover,body.egh-site .main-header-menu>.menu-item>.menu-link:focus,body.egh-site .main-header-menu>.current-menu-item>.menu-link{color:var(--egh-primary)}
body.egh-site .main-header-menu>.egh-menu-item>.menu-link{display:flex;align-items:center}
@media (min-width:922px){
	body.egh-site .ast-builder-menu-1 .main-header-menu{flex-wrap:wrap;justify-content:flex-end}
	body.egh-site .ast-builder-menu-1 .main-header-menu>.menu-item>.menu-link{padding-left:.62em;padding-right:.62em;font-size:.95rem;line-height:1.2}
	body.egh-site .ast-builder-menu-1 .main-header-menu>.current-menu-item>.menu-link{box-shadow:inset 0 -3px 0 var(--egh-primary)}
	body.egh-site .ast-builder-menu-1 .main-header-menu>.egh-menu-item>.menu-link{box-shadow:none}
	body.egh-site .ast-builder-menu-1 .main-header-menu>.egh-menu-login{margin-left:.4em;padding-left:.4em;border-left:1px solid var(--egh-line)}
	body.egh-site .ast-builder-menu-1 .main-header-menu>.egh-menu-coins{margin-left:.4em;padding-left:.4em;border-left:1px solid var(--egh-line)}
}
@media (min-width:922px) and (max-width:1320px){
	body.egh-site .ast-builder-menu-1 .main-header-menu>.menu-item>.menu-link{padding-left:.45em;padding-right:.45em;font-size:.875rem}
	body.egh-site .site-title{font-size:1.2rem}
}
@media (max-width:921px){
	body.egh-site .ast-mobile-header-wrap .main-header-menu>.menu-item>.menu-link{min-height:48px;display:flex;align-items:center;border-color:var(--egh-line)}
	body.egh-site .ast-mobile-header-wrap .main-header-menu>.egh-menu-item>.menu-link{padding-top:6px;padding-bottom:6px}
	body.egh-site .ast-mobile-header-wrap .menu-toggle{min-width:44px;min-height:44px}
}

/* Page content */
body.egh-site.page .site-content>.ast-container{padding-top:20px;padding-top:clamp(20px,4vw,44px);padding-bottom:32px;padding-bottom:clamp(32px,6vw,72px)}
body.egh-site.page #primary{margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0}
body.egh-site.page .entry-header{max-width:760px;margin:0 auto 18px;text-align:left}
body.egh-site.page .entry-header .entry-title{margin:0;color:var(--egh-ink);font-size:1.7rem;font-size:clamp(1.7rem,1.25rem + 2.2vw,2.5rem);font-weight:800;line-height:1.15;letter-spacing:-.01em}
body.egh-site.page .entry-header .entry-title::after{content:"";display:block;width:56px;height:5px;margin-top:12px;border-radius:999px;background:linear-gradient(90deg,var(--egh-primary),var(--egh-gold))}
body.egh-site.egh-has-home .entry-header{display:none}
body.egh-site.page .entry-content>:not(.egh-wide):not(.alignwide):not(.alignfull){max-width:760px;margin-left:auto;margin-right:auto}
body.egh-site.page .entry-content>p{color:var(--egh-text);font-size:1.06rem;line-height:1.65}
body.egh-site.page .entry-content>:is(h2,h3,h4){margin-top:1.6em;margin-bottom:.5em;color:var(--egh-ink);font-weight:800;line-height:1.25}
body.egh-site .entry-content a:is(.egh-btn,.egh-card-link){text-decoration:none}

/* Footer */
body.egh-site .site-footer{border-top:1px solid var(--egh-line);background:#fff}
body.egh-site .site-footer :is(.site-below-footer-wrap,.site-primary-footer-wrap,.site-above-footer-wrap){background:transparent;border-color:var(--egh-line)}
body.egh-site .site-footer,body.egh-site .ast-footer-copyright{color:var(--egh-muted);font-size:.95rem}
body.egh-site .site-footer a{display:inline-block;padding:11px 4px;color:var(--egh-primary-dark);font-weight:600;line-height:22px;text-decoration:none}
body.egh-site .site-footer a:hover,body.egh-site .site-footer a:focus{color:var(--egh-primary);text-decoration:underline}
body.egh-site .site-footer .menu-link{padding:11px 12px}
