@font-face{font-family:Alegreya;src:url('../fonts/Alegreya-Variable.ttf') format('truetype');font-style:normal;font-weight:400 900;font-display:swap}
@font-face{font-family:Alegreya;src:url('../fonts/Alegreya-Italic-Variable.ttf') format('truetype');font-style:italic;font-weight:400 900;font-display:swap}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:#050505;color:#f6f6f6;font-family:Alegreya,Georgia,serif}a{color:inherit}h1,h2,h3,p{margin-top:0}.topbar{position:absolute;z-index:10;top:8px;left:0;width:100%;padding:0 2%}.nav-frame{max-width:1220px;margin:auto;height:74px;background:url('../assets/nav.png') center/100% 100% no-repeat;display:flex;align-items:center;justify-content:space-between;padding:0 6%;gap:25px}.brand{font-size:clamp(17px,2.1vw,25px);font-weight:bold;text-decoration:none;white-space:nowrap;text-shadow:0 2px 3px #000}.nav-links{display:flex;gap:30px;align-items:center}.nav-links a{font-size:14px;font-weight:bold;text-decoration:none}.nav-links a:hover,.brand:hover{color:#c7c7c7}.menu-toggle{display:none;background:none;color:#fff;border:0;font-size:27px}.hero{min-height:720px;background:linear-gradient(to bottom,rgba(0,0,0,.7),transparent 13%,rgba(0,0,0,.05) 33%,#050505 93%),url('../assets/hero.jpg') center top/cover no-repeat;text-align:center;padding:55px 20px 10px}.hero-inner{max-width:1050px;margin:auto}.emblem{width:min(390px,48vw);display:block;margin:0 auto -3px;filter:drop-shadow(0 5px 12px #000)}.eyebrow{font-size:clamp(12px,1.5vw,17px);letter-spacing:.17em;margin:0}.eyebrow span{padding:0 13px}.divider{height:40px;max-width:1100px;margin:0 auto;background:url('../assets/divider.png') center/100% 100% no-repeat}.hero h1{font-size:clamp(36px,5.4vw,63px);margin:0 0 6px;text-shadow:0 3px 5px #000}.intro{font-size:clamp(16px,1.7vw,21px);line-height:1.2;text-shadow:0 2px 4px #000}.pillars{display:flex;align-items:center;justify-content:center;gap:35px;margin:28px auto 5px}.pillars>div{display:flex;gap:15px;align-items:center;justify-content:center;min-width:180px}.pillar-icon{font-size:53px;line-height:1}.pillars strong{font-size:23px;line-height:1.05}.pillars i{font-size:30px;font-style:normal;color:#aaa}.links-section,.rules-section{max-width:1200px;margin:0 auto;text-align:center;padding:0 25px}.links-section h2,.closing h2{font-size:clamp(32px,4vw,49px);margin:0}.section-sub{font-size:19px;margin:0 0 18px}.cards{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:15px}.guild-card{position:relative;min-height:290px;padding:20px 20px 24px;background:url('../assets/card-frame.png') center/100% 100% no-repeat;display:flex;align-items:center;flex-direction:column}.card-visual{height:70px;display:flex;align-items:center;justify-content:center;gap:8px;font-size:50px;color:#ddd;text-shadow:0 3px 5px #000}.discord-symbol{font-size:45px}.guild-card h3{font-size:23px;margin:0 0 7px}.guild-card p{font-size:16px;line-height:1.17;margin:0 0 12px;flex:1}.fantasy-button{background:url('../assets/button.png') center/100% 100% no-repeat;display:inline-flex;align-items:center;justify-content:center;text-decoration:none;font-size:15px;font-weight:bold;min-height:41px;width:100%;max-width:220px;padding:10px 14px;transition:filter .2s,transform .2s}.fantasy-button:hover{filter:brightness(1.4);transform:translateY(-2px)}.rules-section{padding-top:8px}.scroll-wrap{position:relative;max-width:1150px;margin:auto;min-height:440px}.scroll{position:absolute;inset:0;width:100%;height:100%;object-fit:fill}.scroll-content{position:relative;z-index:1;color:#080808;padding:55px 15% 55px;text-align:center}.scroll-content h2{font-size:clamp(26px,3.6vw,43px);margin:0}.rules-sub{font-size:17px;margin:0 0 16px}.scroll-content ol{list-style:none;counter-reset:rule;padding:0;text-align:left;margin:0}.scroll-content li{counter-increment:rule;display:flex;align-items:baseline;gap:13px;margin:8px 0;font-size:clamp(12px,1.25vw,15px);line-height:1.25}.scroll-content li:before{content:counter(rule,decimal-leading-zero);background:#191919;color:#fff;min-width:40px;text-align:center;padding:4px 7px;clip-path:polygon(15% 0,85% 0,100% 50%,85% 100%,15% 100%,0 50%)}.scroll-content li b{display:inline}.books,.pouch{position:absolute;z-index:2;bottom:-15px;width:22%;pointer-events:none}.books{left:-5%}.pouch{right:-4%}.closing{min-height:430px;text-align:center;padding:8px 25px 20px;background:linear-gradient(to bottom,#050505 0%,transparent 35%,#050505 96%),url('../assets/footer.jpg') center bottom/cover no-repeat}.closing p{font-size:20px;margin:9px 0 20px}.join{font-size:23px;max-width:340px;min-height:64px}.footer-divider{margin-top:25px}footer{max-width:1150px;margin:auto;display:flex;justify-content:space-between;font-size:15px;gap:20px;padding:0 8px}
/* v0.2: fixed-width desktop composition */
html{min-width:1200px}
body{background:#000;min-width:1200px}
.site-shell{width:1200px;min-width:1200px;margin:0 auto;position:relative;overflow:hidden}
.topbar{z-index:20;width:1200px;padding:0 12px}
.nav-frame{max-width:none;width:100%;height:74px;padding:0 6%}
.brand{font-size:24px}
.nav-links a{font-size:15px;font-weight:600}
.hero{position:relative;z-index:1}
.hero-inner{position:relative;z-index:21}
.emblem{position:relative;z-index:30;width:390px}
.eyebrow{font-size:17px}
.hero h1{font-size:63px;font-weight:700}
.intro{font-size:21px}
.links-section h2,.closing h2{font-size:49px}
.scroll-content h2{font-size:43px}
/* Rules: badge + bold lead + description on exactly one line. */
.scroll-wrap{min-height:405px}
.scroll-content{padding:43px 10% 40px}
.scroll-content li{font-size:14px;line-height:1.2;gap:10px;margin:8px 0;align-items:center;white-space:nowrap}
.scroll-content li::before{flex:0 0 40px;min-width:40px;font-size:14px}
.rule-line{display:inline;white-space:nowrap}
.rule-line strong{font-weight:700}
.rules-sub{margin-bottom:15px}
/* v0.3: allow the guild emblem to paint above the navigation artwork.
   The hero must not establish a lower stacking context than the nav. */
.topbar{z-index:5}
.hero{z-index:auto}
.hero-inner{position:relative;z-index:10}
.emblem{position:relative;z-index:11}
/* v0.3: inset rule text 15% from either side of the scroll. */
.scroll-content{padding:43px 0 40px}
.scroll-content ol{width:70%;margin:0 auto;text-align:left}
.scroll-content li{font-size:13px;gap:9px}
.scroll-content li::before{flex:0 0 38px;min-width:38px}
/* v0.3: crop excess black below the copyright without resizing artwork. */
.closing{min-height:0;height:350px;padding-bottom:0;background-position:center top;overflow:hidden}
/* v0.4: raise logo to overlap menu by approximately 5px; add breathing room below. */
.emblem{top:-52px;margin-bottom:-35px}
/* v0.4: inset rule list to 60% of the parchment, centered; retain single-line text. */
.scroll-content ol{width:60%;margin:0 auto;text-align:left}
/* v0.5 — lower the entire content beginning with the three-part tagline,
   without moving or resizing the guild emblem, navigation, or hero artwork. */
.hero .eyebrow{margin-top:70px}
.hero{min-height:790px}

/* v0.6 — illustrated community cards. Backgrounds and gradient are clipped
   inside the ornate silver frame; the frame remains at its original scale. */
.guild-card{isolation:isolate;background:none;overflow:hidden;justify-content:flex-start;padding:20px 20px 24px}
.guild-card::after{content:"";position:absolute;inset:0;background:url('../assets/card-frame.png') center / 100% 100% no-repeat;z-index:5;pointer-events:none}
.card-backdrop{position:absolute;inset:9px 10px 10px;z-index:-1;pointer-events:none;clip-path:polygon(7% 0,93% 0,100% 7%,100% 93%,93% 100%,7% 100%,0 93%,0 7%);background-position:center top;background-size:cover;background-repeat:no-repeat}
.card-backdrop::after{content:"";position:absolute;inset:0;background:linear-gradient(to bottom,rgba(0,0,0,.05) 0%,rgba(0,0,0,.34) 26%,rgba(0,0,0,.83) 53%,#000 72%,#000 100%)}
.guild-card--discord .card-backdrop{background-image:url('../assets/discord-bg.png')}
.guild-card--tabletop .card-backdrop{background-image:url('../assets/tabletop-bg.png')}
.guild-card--wow .card-backdrop{background-image:url('../assets/wow-bg.png')}
.guild-card--resources .card-backdrop{background-image:url('../assets/resources-bg.png')}
.guild-card .card-visual{position:relative;z-index:1;height:70px;flex:0 0 70px;width:100%;filter:drop-shadow(0 2px 3px #000)}
.guild-card .card-visual img{display:block;width:57px;height:57px;object-fit:contain}
.guild-card h3,.guild-card p,.guild-card .fantasy-button{position:relative;z-index:2;text-shadow:0 2px 3px #000}
.guild-card .fantasy-button{z-index:6}

/* v0.7: show the entire width of each community illustration. */
.card-backdrop{background-size:100% auto;background-position:center top;background-color:#000}
/* v0.7: lower the first hero separator and everything following it by 60px.
   Position the tagline midway between the logo tip and that separator. */
.hero .eyebrow{margin-top:55px}
.hero-inner > .divider{margin-top:75px}
.hero{min-height:850px}

/* v0.8: tagline 30px lower; all following content remains stationary. */
.hero .eyebrow{position:relative;top:30px}
/* Navigation labels without icons, preserving the former icon space. */
.nav-links a{display:inline-flex;align-items:center;justify-content:center;min-width:78px}
/* Feature artwork, visually balanced across the three headings. */
.pillar-icon-img{width:55px;height:55px;object-fit:contain;display:block;flex:0 0 55px;filter:drop-shadow(0 2px 3px #000)}
.pillar-icon-community{width:60px;height:60px;flex-basis:60px}

/* v0.9 — discreet interactive D20, with no changes to existing layout. */
.hero-divider{position:relative}
.fate-die{position:absolute;z-index:22;left:calc(50% + 240px);margin-top:-36px;width:39px;height:39px;padding:3px;background:radial-gradient(circle,#2b2b2b,#070707);border:1px solid #8c8c8c;border-radius:50%;box-shadow:0 2px 9px #000;cursor:pointer;transition:filter .2s,transform .25s}
.fate-die svg{width:100%;height:100%;display:block}
.fate-die:hover,.fate-die:focus-visible{filter:drop-shadow(0 0 8px #fff);transform:rotate(18deg) scale(1.12);outline:1px solid #aaa;outline-offset:3px}
.dice-layer{position:fixed;inset:0;z-index:1000;pointer-events:none;visibility:hidden;opacity:0;transition:opacity .25s;overflow:hidden;font-family:Alegreya,Georgia,serif}
.dice-layer.active{visibility:visible;opacity:1}
#dice-canvas{width:100%;height:100%;display:block}
.dice-result{position:absolute;left:50%;bottom:11%;transform:translateX(-50%);min-width:260px;max-width:90vw;text-align:center;padding:13px 30px;color:#f3f3f3;background:linear-gradient(90deg,transparent,rgba(0,0,0,.92) 17%,rgba(0,0,0,.92) 83%,transparent);font-size:25px;letter-spacing:.03em;text-shadow:0 2px 5px #000;opacity:0;transition:opacity .5s;white-space:normal}
.dice-result.visible{opacity:1}
.dice-result strong{display:block;font-size:37px;line-height:1.1}
.dice-mute,.dice-close{position:absolute;top:18px;pointer-events:auto;color:#eee;background:rgba(10,10,10,.88);border:1px solid #999;border-radius:50%;width:37px;height:37px;font-size:23px;cursor:pointer;display:none}
.dice-mute{right:66px}.dice-close{right:18px}.dice-layer.active .dice-mute,.dice-layer.active .dice-close{display:block}
.dice-mute:hover,.dice-close:hover{background:#444}
@media (prefers-reduced-motion:reduce){.fate-die,.dice-layer,.dice-result{transition:none}}

/* v0.9.2 — 40% black full-viewport scrim beneath the die and result. */
.dice-layer::before{content:"";position:absolute;inset:0;background:rgba(0,0,0,.75);z-index:0;pointer-events:none}
#dice-canvas{position:relative;z-index:1}
.dice-result,.dice-mute,.dice-close{z-index:2}

/* v0.9.4 — readable narrative results, without obscuring the die */
.dice-result{bottom:3%;width:min(680px,calc(100vw - 44px));max-width:calc(100vw - 44px);box-sizing:border-box;padding:16px 25px 18px;background:rgba(0,0,0,.92);border:1px solid #777;border-radius:7px;box-shadow:0 5px 35px #000;font-size:18px;line-height:1.35;max-height:43vh;overflow-y:auto;pointer-events:none}
.dice-result.visible{pointer-events:auto}
.dice-result strong{font-size:32px;margin:3px 0 5px}
.dice-kicker{display:block;font-size:12px;letter-spacing:.2em;color:#bbb}
.dice-story-title{display:block;font-size:23px;font-weight:700;margin-bottom:7px}
.dice-story-body{display:block;font-size:18px;line-height:1.4;letter-spacing:0}
.dice-reroll{display:block;margin:13px auto 0;padding:8px 23px;border:1px solid #aaa;color:#fff;background:#222;font:700 15px Alegreya,Georgia,serif;letter-spacing:.09em;cursor:pointer}
.dice-reroll:hover,.dice-reroll:focus-visible{background:#555}
@media(max-height:620px){.dice-result{max-height:48vh;padding:10px 16px}.dice-result strong{font-size:26px}.dice-story-title{font-size:20px}.dice-story-body{font-size:16px}}

/* v0.9.5 — centre the Easter-egg D20 between emblem and tagline.
   Visual-only offsets preserve the divider and all document flow. */
.hero .eyebrow{top:45px}
.fate-die{left:50%;top:365px;margin-top:0;transform:translateX(-50%);animation:fate-heartbeat 3.6s ease-in-out infinite;transform-origin:center}
@keyframes fate-heartbeat{
  0%,100%{transform:translateX(-50%) scale(1);filter:drop-shadow(0 0 0 rgba(255,255,255,0))}
  50%{transform:translateX(-50%) scale(1.16);filter:drop-shadow(0 0 6px rgba(255,255,255,.55))}
}
.fate-die:hover,.fate-die:focus-visible{animation-play-state:paused;transform:translateX(-50%) rotate(18deg) scale(1.2)}
@media(prefers-reduced-motion:reduce){.fate-die{animation:none}}
