
/*CARD */

.card {
    position: relative;
    float: left; /* float-based multi-column layout */
    width: 100%;
    margin: 0 0 2% 0; /* vertical spacing */
}

.card::before {
    content: "";
    display: block;
    padding-top: 100%; /* enforce perfect square height based on width */
}

.card__container {
    position: fixed;
    top: 0;
    left: 0;
    overflow-x: hidden;
    overflow-y: auto;
    width: 100%;
    height: 100%;
    -webkit-overflow-scrolling: touch;
}

.card__container--closed {
    position: absolute;
    overflow: hidden;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.card__image {
    position: absolute;
    top: 0;
    left: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover; /* cover square */
}

.card__container--closed .card__image {
	position: relative;
	cursor: pointer;
}
/* Fix IE */

.card__container--fix-image .card__image {
	position: fixed;
}

.card__content {
	position: relative;
    width: 100%;
    max-width: 80%;
	height: auto;
	margin: 400px auto 60px;
	padding: 30px 40px 22px;
	background: #fff;
    border-radius: 16px;
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.card__container--closed .card__content {
	margin-top: 0;
	padding: 0 16px;
	pointer-events: none;
	background: transparent;
}

.card__caption {
	font-size: 2em;
	max-width: 800px;
	margin: 0 auto;
	padding: 35px 30px 0px;
}

.card__container--closed .card__caption {
	font-size: 1em;
	max-width: auto;
	padding: 10px 10px 25px;
	-webkit-transform: translateY(-100%);
	-ms-transform: translateY(-100%);
	transform: translateY(-100%);
}

.card__title {
	font-size: 1.5em;
	line-height: 1;
	margin: 5px 0 0 0;
	color: #3b393d;
}

.card__container--closed .card__title {
	color: #fff;
}

.card__subtitle {
	font-size: .95em;
	line-height: 1;
	margin: 5px 0 0;
	color: #777778;
}

.card__container--closed .card__subtitle {
	color: #f5f5f5;
}

.card__copy {
	font-size: 1.25em;
	max-width: 900px;
	margin: 0 auto;
	padding: 25px 30px 100px;
	color: #3b393d;
}

/* Album post header */
.album-meta {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 16px;
    align-items: center;
    margin: 0 auto 1rem;
    max-width: 900px;
    padding: 25px 30px 0;
}
.album-cover {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
}
.album-info { display: flex; flex-direction: column; gap: 6px; }
.album-title { margin: 0; font-size: 1.4em; line-height: 1.2; }
.album-stats { font-size: 0.9em; color: #666; display: flex; gap: 12px; }
.album-stats .album-year::after { content: "•"; margin-left: 12px; }
.album-stats .album-year:last-child::after { content: ""; margin: 0; }

@media (min-width: 900px) {
  .album-meta { grid-template-columns: 180px 1fr; gap: 20px; }
  .album-cover { width: 180px; height: 180px; border-radius: 12px; }
  .album-title { font-size: 2rem; }
}

.card__copy p {
	font-size: 1.5em;
	padding: 0 0 1em 0;
}

.card__copy p:first-of-type {
	font-size: 1.5em;
	padding: 0 0 1em 0;
}

.card__copy p a {
	text-decoration: none;
	color: #de6551;
	outline: none;
}

.card__btn-close {
	font-size: 18px;
	position: absolute;
	top: 0;
	right: 0;
	padding: 36px;
	cursor: pointer;
}

.card__container--closed .card__btn-close {
	display: none;
}

.meta {
	font-size: .85em;
	display: -webkit-flex;
	display: flex;
	padding: 0 0 35px 0;

	-webkit-align-items: center;
	align-items: center;
}

.meta__avatar {
	border-radius: 50%;
	height: 50px;
	width: 50px;
}

.meta__author {
	font-weight: bold;
	padding: 0 15px;
}

.meta__date {
	margin: 0 0 0 auto;
}

@media only screen and (max-width: 980px) {
    .card__content {
		margin-bottom: 0;
		padding-right: 20px;
		padding-left: 20px;
	}
}

@media only screen and (max-width: 580px) {
}

@media only screen and (max-width: 400px) {
	.card__caption {
		font-size: 1.25em;
		padding: 35px 0px 0px;
	}
	.meta {
		padding: 0 0 25px 0;
	}
	.card__copy {
		font-size: 90%;
		padding: 25px 0px 100px;
	}
}


*,
*:after,
*:before {
	-webkit-box-sizing: border-box;
	box-sizing: border-box;
}

.clearfix:before,
.clearfix:after {
	content: '';
	display: table;
}

.clearfix:after {
	clear: both;
}

body {
	font-family: Avenir, 'Helvetica Neue', 'Lato', 'Segoe UI', Helvetica, Arial, sans-serif;
	line-height: 1.5;
	color: #3b393d;
	background: #f0f0f0;
	background-size: cover;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow: hidden;
	overflow-y: scroll;
    scrollbar-gutter: stable both-edges;
}

body.body--hidden {
    overflow: hidden; /* disable page scroll while post is open to avoid double scrollbars */
    scrollbar-gutter: stable both-edges; /* maintain scrollbar space even when overflow is hidden */
}

body.body--hidden .header {
	opacity: 0;
}

.header{
	-webkit-transition: opacity 300ms ease-in-out;
	transition: opacity 300ms ease-in-out;
}

a {
	text-decoration: none;
	color: #de6551;
	outline: none;
}

a:hover,
a:focus {
	color: #3b393d;
}

.body {
	background: linear-gradient(135deg, #b8dde0 0%, #85c1c6 20%, #9CCACB 40%, #7bb3b5 60%, #a2d1d4 80%, #8bc4c7 100%);
}

.body a {
	color: #4f4c4c;
}

.body .header h1 span {
	color: #4f4c4c;
}

.hidden {
	position: absolute;
	overflow: hidden;
	width: 0;
	height: 0;
	pointer-events: none;
}
/* Header */

.header {
    padding: 2em 1em;
    text-align: center;
}

.header--hero { padding: 1em 0; }

@media only screen and (max-width: 900px) {
    .header--hero { padding: 0.5em 0; }
}

@media only screen and (max-width: 580px) {
    .header--hero { padding: 0; }
}

/* Match header wrapper side padding to albums grid */
.header--hero > .wrapper {
    padding-left: 4%;
    padding-right: 4%;
}

.header--hero {
    padding-left: 0;
    padding-right: 0;
}

.header--hero {
    text-align: left;
}

.header--hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    line-height: 1.1;
    font-weight: 800;
    margin: 0.25em 0 0;
}

.header--hero h1 > span {
    display: block;
    font-size: 0.52em;
    font-weight: 500;
    color: #3b393d;
}

.header h1 {
	font-size: 3em;
	font-weight: 800;
	line-height: 1.2;
	margin: .5em 0 0;
}

.header h1 span {
	font-weight: 400;
	font-size: .45em;
	display: block;
    padding: .25em 0 .75em;
	color: #999;
}
/* Top Navigation Style */

.links {
    margin: 1em 0 0;
}

.links a {
	display: inline-block;
    margin: 0 .5em;
}

.header--hero .links a {
    margin: 0 .5em .5em 0; /* remove left margin, keep right spacing */
}

/* Stack playlist links horizonally in the hero */
.header--hero .links {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-start;
}

.playlist-cta {
    margin-top: .5em;
    font-weight: 700;
    color: #3b393d;
}

/* Hero layout */
.hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    align-items: start;
}

@media (min-width: 900px) {
    .hero {
        grid-template-columns: 1.2fr 1fr;
        gap: 32px;
    }
}

/* Align first card in each row flush with wrapper padding */
/* Grid-like columns with floats and percentage gutters */
@media only screen and (min-width: 981px) {
    .wrapper .card { width: calc((100% - (2% * 2)) / 3); margin-right: 2%; }
    .wrapper .card:nth-child(3n) { margin-right: 0; }
}

@media only screen and (max-width: 980px) and (min-width: 581px) {
    .wrapper .card { width: calc((100% - 2%) / 2); margin-right: 2%; }
    .wrapper .card:nth-child(2n) { margin-right: 0; }
}

@media only screen and (max-width: 580px) {
    .wrapper .card { width: 100%; margin-right: 0; }
}

.hero__right .twitch-embed {
    width: 100%;
    aspect-ratio: 16 / 9;
    margin-top: 1.5rem;
}

.hero__right .twitch-caption {
    margin-top: 0.5rem;
    font-weight: 600;
		font-style: italic;
		opacity: 0.7;
    color: #3b393d;
    text-align: center;
}

/* Playlist buttons */
.playlist-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    border-radius: 999px;
    font-weight: 700;
    text-decoration: none;
    border: 2px solid transparent;
    transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease, transform 80ms ease;
}

.playlist-button i { font-size: 1.2em; }

.playlist-button--spotify {
    background: #1DB954;
    color: #fff;
}
.playlist-button--spotify i { color: #fff; }
.body .playlist-button--spotify { color: #fff; }
.body .playlist-button--spotify i { color: #fff; }
.playlist-button--spotify:hover,
.playlist-button--spotify:focus {
    background: #17a74b;
    color: #fff;
}

.body .playlist-button--apple {
    background: #000;
    color: #fff;
}
.body .playlist-button--apple i { color: #fff; }
.body .playlist-button--apple:hover,
.body .playlist-button--apple:focus {
    background: #111;
    color: #fff;
}

.playlist-button:active { transform: translateY(1px); }

/* Hover interactions for playlist links in hero */
.header--hero .playlist-button { will-change: transform, opacity; }
.header--hero .playlist-button:hover,
.header--hero .playlist-button:focus {
    transform: translateY(-2px);
}
.header--hero .playlist-button--apple:hover,
.header--hero .playlist-button--apple:focus {
    opacity: 0.9;
}

/* YouTube button */
.playlist-button--youtube {
    background: #FF0000;
    color: #fff;
}
.playlist-button--youtube i { color: #fff; }
.body .playlist-button--youtube { color: #fff; }
.body .playlist-button--youtube i { color: #fff; }
.playlist-button--youtube:hover,
.playlist-button--youtube:focus {
    background: #e40000;
    color: #fff;
}

/* cards wrapper and close btn */

.wrapper {
    overflow: visible;
    width: 100%;
    max-width: 1366px;
    margin: 0 auto;
    padding-left: 2%;
    padding-right: 2%;
}

/* Ensure only the albums grid manages its own bottom spacing */
/* Removed generic .content .wrapper padding to avoid affecting the hero */

.section-title {
    font-size: clamp(1.4rem, 3.2vw, 2rem);
    font-weight: 800;
    margin: 1.25em 0 0.75em;
    color: #3b393d;
    transition: opacity 300ms ease-in-out;
}
/* Align section title with increased albums padding */
.section-title { padding-left: 0; padding-right: 0; }

/* Align the header with the left edge of the album cards */
.wrapper--albums-header { padding-left: 4%; padding-right: 4%; }

/* Hide the albums header during card open transition */
.body--hidden .wrapper--albums-header,
.body--hidden .section-title {
    opacity: 0;
}

@media only screen and (max-width: 580px) {
    .section-title { margin-top: 2.25em; }
}

/* Extra spacing for albums grid on mobile */
@media only screen and (max-width: 580px) {
    .cards { margin-top: 0.75em; }
}

@media screen and (max-width: 50em) {
	.header {
		padding: 3em 5% 3em;
	}
}

@media screen and (max-width: 40em) {
	.header h1 {
		font-size: 2.4em;
		line-height: 1.2;
	}
}

/* PATTERN */

.pattern {
	position: fixed;
	z-index: -1;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
    background: linear-gradient(135deg, #a8d0d3 0%, #7bb3b5 35%, #9CCACB 65%, #8bc4c7 100%) no-repeat center center / cover;
    transition: opacity 1s ease-in-out;
}

.pattern--hidden {
	opacity: 0;
}

.pattern svg {
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
}

.pattern:not(.pattern--hidden) svg {
    opacity: 1;
}

.pattern--hidden .polygon {
	transition-duration: 0ms;
}

.pattern svg {
	width: 100%;
	height: 100%;
}

.polygon {
	transition: -webkit-transform 300ms ease-in-out, opacity 300ms ease-in-out;
	transition: transform 300ms ease-in-out, opacity 300ms ease-in-out;
	-webkit-transform: scale(1);
	transform: scale(1);
	-webkit-transform-origin: center bottom;
	transform-origin: center bottom;
}

.polygon--hidden {
	opacity: 0;
	-webkit-transform: scale(0);
	transform: scale(0);
}
/* disable scale on firefox */

.ff .polygon {
	-webkit-transform: scale(1)!important;
	transform: scale(1)!important;
}

/* Cards: switch to CSS Grid for even columns and true square items */
.cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2%;
}

/* Extra spacing after the albums grid so it doesn't collide with the footer */
.wrapper.cards { margin-bottom: 15rem; }
/* Footer */
.site-footer {
    background: #111;
    color: #ddd;
    margin-top: 3rem;
    padding: 4.5rem 2.5rem 3.5rem;
    clear: both; /* guard against any legacy floats above */
}

.footer__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.25rem;
    margin-bottom: 2rem; /* extra space above fine print */
}

@media (min-width: 900px) {
    .footer__inner { grid-template-columns: 1fr 2fr; }
}

.footer__title { font-weight: 800; font-size: 1.75rem; color: #fff; }
.footer__subtitle { color: #aaa; font-size: 1rem; margin-top: 0.25rem; }

.footer__links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 2rem;
}

.footer__heading { font-size: 1rem; margin: 0 0 .5rem; color: #fff; }
.footer-link {
    display: flex; /* stack links vertically */
    align-items: center;
    gap: 8px;
    color: #ddd;
}
.footer-link:hover, .footer-link:focus { color: #fff; }

.footer__fineprint { text-align: center; margin-top: 3rem; color: #888; }

/* Desktop: increase footer typography sizes */
@media (min-width: 1024px) {
  .footer__title { font-size: 2.25rem; }
  .footer__subtitle { font-size: 1.125rem; }
  .footer__heading { font-size: 1.125rem; }
  .footer-link { font-size: 1.125rem; }
  .footer-link i { font-size: 1.25em; }
}

/* Increase side padding specifically for albums grid */
.wrapper.cards { padding-left: 4%; padding-right: 4%; }

.cards .card {
    float: none;
    width: auto;
    margin: 0; /* spacing handled by grid gap */
    aspect-ratio: 1 / 1;
}

.cards .card::before { content: none; }

@media only screen and (max-width: 980px) and (min-width: 581px) {
    .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media only screen and (max-width: 580px) {
    .cards { grid-template-columns: 1fr; gap: 0.5%; }
}

/* Increase side padding for album section wrappers on mobile */
@media only screen and (max-width: 580px) {
    .content .wrapper {
        padding-left: 8%;
        padding-right: 8%;
    }
}
