/* Imports */

@import url('../fonts/armin-soft/stylesheet.css');
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&family=Space+Mono:ital,wght@0,400;0,700;1,400;1,700&display=swap');
@import url('../font-awesome/css/all.css');

/* Colours */

:root {
    --stardust-speedway-purple: #30097E;
    --casino-nights-black: #000000;
    --casino-nights-gold: #b09a17;
    --casino-nights-pink: #bf30a3;

    --dusk-blue: #465775;
    --blue-bell: #20a4f3;
    --neon-ice: #59f8e8;
    --light-neon-ice: #e1ffff;
    --burgundy: #941c2f;
    --banana-cream: #fff07c;
    --peach-fuzz: #ffd5c2;
    --light-warning-crimson: #fff3f2;
    --light-meteor-orange: #fae8e0;

    /* Stardust Speedway */
    --speedway-midnight: #0f0226;
    --laser-indigo: #240b4f;
    --metal-blue: #1a1f38;
    --neon-overdrive: #e5007d;

    /* Casino Night */
    --casino-void: #0a0a14;
    --velvet-maroon: #4a0e17;
    --slot-gold: #d4af37;
    --neon-magenta: #ff007f;

    /* Death Egg Core */
    --death-egg-hull: #16191e;
    --hangar-shadow: #212730;
    --power-grid-blue: #00a3e0;
    --warning-crimson: #c8102e;

    /* Final Rush */
    --space-abyss: #020208;
    --cosmic-nebula: #180d2c;
    --grind-rail-cyan: #00f5ff;
    --meteor-orange: #ff7733;

    /* An Iconic Special */

    --green-hills: #2bb800;
}

/* Background */

body {
    /* 1. Add your image file path here */
    background-image: url('../img/spring-yard-zone.png'); 
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    
    position: relative;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
}

body:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    
    background-color: color-mix(in hsl, var(--banana-cream), transparent 40%);
    backdrop-filter: blur(10px);
    
    pointer-events: none;
}

/* Text */

h1, h2, h3, h4, h5, h6, h1 > a, h2 > a, h3 > a, h4 > a, h5 > a, h6 > a {
    color: var(--burgundy);
    font-family: 'Armin Soft Ultra';
}

p, a.nav-links, .post-content > ul > li {
    color: var(--stardust-speedway-purple);
    font-family: 'DM Sans', sans-serif;
}

.post-content > ul > li, time {
    color: var(--dusk-blue);
}

time {
    font-family: "Space Mono", monospace;
}

a {
    text-decoration: none;
}

/* Text Sizing */

h1 {
    font-size: clamp(1.75rem, 4vw + 1rem, 3rem);
    margin-bottom: clamp(1rem, 2vw, 1.5rem);
}

h2 {
    font-size: clamp(1.375rem, 3vw + 0.75rem, 2.25rem);
    margin-bottom: clamp(0.75rem, 1.5vw, 1.25rem);
}

h3 {
    font-size: clamp(1.125rem, 2vw + 0.5rem, 1.75rem);
    margin-bottom: clamp(0.5rem, 1vw, 1rem);
}

h4, h5, h6 {
    font-size: clamp(1rem, 1.5vw + 0.5rem, 1.375rem);
    margin-bottom: clamp(0.5rem, 1vw, 0.75rem);
}

p, a, li {
    font-size: clamp(0.938rem, 0.5vw + 0.8rem, 1.125rem);
    font-family: 'DM Sans', sans-serif;
}

p {
    margin-bottom: clamp(0.75rem, 1vw, 1.25rem);
}

span, time, .post-summary {
    font-size: clamp(0.813rem, 0.3vw + 0.75rem, 0.938rem);
    margin-bottom: 0;
}

/* blockquotes */

blockquote {
    border-left: 3px solid var(--casino-nights-pink);
    padding: 0.5rem;
    background-color: color-mix(in srgb, var(--casino-nights-pink) 20%, transparent);   
}

blockquote > p {
    box-sizing: border-box;
}

blockquote > p > a {
    color: var(--casino-nights-pink);
    overflow-wrap: break-word;
    word-break: break-word;   
}

/* Navigation */

ul.nav {
    list-style-type: none;
    margin: 0px;          
    padding: 0;
    background-color: var(--peach-fuzz);
    width: 180px;

    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

ul.nav > li a {
    display: block;
    padding: 8px 16px;
    text-decoration: none;
}

ul.nav > li a:hover {
    color: var(--light-neon-ice);
    background-color: var(--burgundy);
}

.main-link {
    border-bottom: 0.2px dashed var(--casino-nights-black);
    margin-bottom: 0;
}

.secondary-links {
    margin-top: -10px;
}

/* Layout Wrapper */

.site-layout {
    display: flex;         
    align-items: flex-start; 
    width: 100%;
    flex: 1;
}

main {         
    max-width: 800px;
    margin: 0 auto;        
    padding: 20px 40px;   

    box-sizing: border-box;
    background-color: var(--light-warning-crimson);
    position: relative;
}

/* Post Container - Home */

.cluster-heading {
    text-align: center;
    top: -30px;
    position: relative;
}

.cosmic-cluster {
    padding: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
}

.stardust-fragment:nth-child(odd) {
    border-right: 0.2px dashed var(--stardust-speedway-purple);
}

.stardust-fragment {
    padding: 5px 10px;
}

.stardust-thumbnail {
    max-width: 15rem;
    margin-bottom: -40px;
    margin-top: -30px;
}

/* Blog Post - Container */

.post-thumbnail > img {
    max-height: 15rem;
    width: auto;
    margin-left: -2.5rem;
}

.post-single {
    padding: 10px;
}

.post-content > ul > li {
    margin-top: 20px;
}

/* Pagination */

.pagination {
    display: flex;
    list-style: none;
    padding: 0;
    margin-top: 40px;
    gap: 15px;
    justify-content: center;
}

.pagination a {
    color: var(--stardust-speedway-purple);
    font-family: 'DM Sans', sans-serif;
    font-weight: bold;
}

.pagination .active a {
    color: var(--burgundy);
    border-bottom: 2px solid var(--burgundy);
}

/* Responsive Layout Adjustments */
@media (min-width: 768px) and (max-width: 1440px) {
    .site-layout {
        display: flex;
        flex-direction: row;
        gap: 2rem;
        max-width: 1000px;
        margin: 0;
        padding: 2rem 2rem 2rem 0;
    }

    ul.nav {
        flex-shrink: 0;
        margin-top: -2rem;
    }

    main {
        flex: 1;
        min-width: 0;
        margin: 0;
        max-width: 900px;
    }

    .post-single {
        padding: 2rem;
    }
}   

/* Small laptop / large tablet */
@media (min-width: 600px) and (max-width: 767px) {
    .site-layout {
        display: flex;
        flex-direction: column;
        max-width: 700px;
        margin: 0 auto;
        padding: 1rem;
    }

    ul.nav {
        width: 100%;
        display: flex;
        flex-direction: column;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
}

/* Mobile */
@media (max-width: 600px) {
    .site-layout {
        display: block;
    }

    .post-thumbnail > img {
        max-height: 12rem;
    }

    ul.nav {
        width: 100%;
        display: flex;
        flex-direction: column;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    main {
        max-width: 100%;
        margin: 0;
        padding: 15px;
    }   

    .cosmic-cluster {
        grid-template-columns: 1fr;
    }

    .stardust-fragment {
        padding: 15px 10px;
    }

    .stardust-fragment:nth-child(2n+1) {
        border-right: none;
    }

    .stardust-fragment:not(:last-child) {
        border-bottom: 0.2px dashed var(--stardust-speedway-purple);
    }

    .stardust-thumbnail {
        max-width: 20rem;
        display: block;
        margin: auto;
    }

    .stardust-fragment {
        text-align: center;
    }
}

/* Small phone */
@media (max-width: 480px) {
    main {
        padding: 0;
    }

    .post-single {
        padding: 15px;
    }

    .speedway-broadcast {
        top: 20px;
        position: relative;
    }
}   

/* Footer */

.site-layout {
    flex: 1;
}

footer {
  width: 100%;
  height: 50px;
}   

footer {
    background-image: linear-gradient(90deg, var(--speedway-midnight) 0%, var(--laser-indigo) 14%, var(--metal-blue) 28%, var(--casino-void) 42%, var(--space-abyss) 57%, var(--cosmic-nebula) 71%, var(--death-egg-hull) 85%, var(--hangar-shadow) 100%);
}

footer > p {
    text-align: center;
    color: var(--slot-gold);
}

footer > p > a {
    color: var(--meteor-orange);
}

/* hover states */

.fa-palette:hover {
    color: var(--grind-rail-cyan);
}

.fa-heart:hover {
    color: var(--casino-nights-pink);
}

.fa-code:hover {
    color: var(--blue-bell);
}

/* special footer links */

.me, .hugo, .prose, .obsidian {
  position: relative;
  display: inline-block; 
  text-decoration: none;
  transition: color 0.3s ease;
}

.me::before, .hugo::before, .prose::before, .obsidian::before {
  content: "";
  position: absolute;
  display: block;
  width: 100%;
  height: 2px;
  bottom: -2px;
  left: 0;
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.me:hover::before, .hugo:hover::before, .prose:hover::before, .obsidian:hover::before {
  transform: scaleX(1);
}

.me:hover { color: var(--power-grid-blue); }
.me::before { background-color: var(--power-grid-blue); }

.hugo:hover { color: var(--green-hills); }
.hugo::before { background-color: var(--green-hills); }

.obsidian:hover { color: var(--neon-overdrive); }
.obsidian::before { background-color: var(--neon-overdrive); }

.prose:hover { color: var(--light-neon-ice); }
.prose::before { background-color: var(--light-neon-ice); }
