* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Georgia', serif;
    background: linear-gradient(135deg, #1a2420 0%, #2c3e2d 100%);
    min-height: 100vh;
    padding: 2rem;
    color: #e8e2d4;
}

body.light-mode {
    background: linear-gradient(135deg, #f4f1e8 0%, #e8e2d4 100%);
    color: #2c3e2d;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.theme-toggle {
    position: fixed;
    top: 2rem;
    right: 2rem;
    background: #f4f1e8;
    color: #1a2420;
    border: none;
    padding: 0.75rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    z-index: 1000;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

body.light-mode .theme-toggle {
    background: #5a7a5c;
    color: white;
}

body.light-mode .theme-toggle:hover {
    background: #4a6a4c;
}

header {
    text-align: center;
    margin-bottom: 3rem;
}

h1 {
    font-size: 3rem;
    font-weight: bold;
    color: #e8e2d4;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 0px #3a5a3c;
    transition: all 0.3s ease;
}

body.light-mode h1 {
    color: #2c3e2d;
    text-shadow: 2px 2px 0px #d4c5a0;
}

.subtitle {
    font-size: 1.2rem;
    color: #a8b5ab;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

body.light-mode .subtitle {
    color: #5a6b5d;
}

.intro {
    font-size: 1.1rem;
    color: #9aa59d;
    max-width: 600px;
    margin: 0 auto 2rem;
    line-height: 1.6;
    transition: color 0.3s ease;
}

body.light-mode .intro {
    color: #4a5a4d;
}

.cards-grid {
    display: grid;
    gap: 2rem;
    justify-content: center;
    max-width: 1000px;
    margin: 0 auto;
}

.card-container {
    width: 310px;
    height: 564px;
    perspective: 1000px;
}

.card {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    cursor: pointer;
}

.card.flipped {
    transform: rotateY(180deg) !important;
}

.card-face {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border: 4px solid #2c3e2d;
    border-radius: 8px;
    background: #f9f6f0;
    box-shadow: 0 8px 16px rgba(44, 62, 45, 0.3);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

body.light-mode .card-face {
    border-color: #2c3e2d;
    background: #f9f6f0;
    box-shadow: 0 8px 16px rgba(44, 62, 45, 0.3);
}

.card-back {
    transform: rotateY(180deg);
}

.card-front {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
}

.card-number {
    font-size: 2rem;
    font-weight: bold;
    color: #e8e2d4;
    margin-bottom: 1rem;
}

body.light-mode .card-number {
    color: #2c3e2d;
}

.card-image {
    flex: 1;
    background: linear-gradient(135deg, #d4c5a0 0%, #c7b896 100%);
    border: 2px solid #2c3e2d;
    border-radius: 4px;
    margin-bottom: 1rem;
    position: relative;
    overflow: hidden;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.sleuth-image {
    background-image: url('images/sleuth.png');
}

.prototypist-image {
    background-image: url('images/prototypist.png');
}

.scout-image {
    background-image: url('images/scout.png');
}

.multidisciplinarian-image {
    background-image: url('images/multidisciplinarian.png');
}

.explorer-image {
    background-image: url('images/explorer.png');
}

.storyteller-image {
    background-image: url('images/storyteller.png');
}

.card-title {
    font-size: 1.1rem;
    font-weight: bold;
    text-align: center;
    color: #e8e2d4;
    background: #2a3d2c;
    padding: 0.5rem 0.25rem;
    border: 2px solid #e8e2d4;
    border-radius: 4px;
    line-height: 1.2;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

body.light-mode .card-title {
    color: #2c3e2d;
    background: #f9f6f0;
    border-color: #2c3e2d;
}

.card-back {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: #1f2e21;
    transition: background 0.3s ease;
}

body.light-mode .card-back {
    background: #f4f1e8;
}

.card-back h3 {
    font-size: 1.5rem;
    color: #e8e2d4;
    margin-bottom: 0;
    text-align: center;
    transition: color 0.3s ease;
}

body.light-mode .card-back h3 {
    color: #2c3e2d;
}

.card-back-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1rem 0;
}

.card-back p {
    color: #9aa59d;
    line-height: 1.6;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.card-back p:last-child {
    margin-bottom: 0;
}

body.light-mode .card-back p {
    color: #4a5a4d;
}

.expand-icon {
    background: none;
    color: #9aa59d;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    font-size: 1.5rem;
    margin-top: 0;
    align-self: center;
    transition: color 0.3s, transform 0.3s;
}

.expand-icon:hover {
    color: #e8e2d4;
    transform: translateY(2px);
}

body.light-mode .expand-icon {
    color: #5a6b5d;
}

body.light-mode .expand-icon:hover {
    color: #2c3e2d;
}


footer {
    margin-top: 4rem;
    padding: 2rem;
    border-top: 2px solid #3a5a3c;
}

body.light-mode footer {
    border-color: #d4c5a0;
}

.social-links {
    margin-bottom: 1rem;
    text-align: center;
}

.social-links a {
    color: #f4f1e8;
    text-decoration: none;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: #ffffff;
}

body.light-mode .social-links a {
    color: #5a7a5c;
}

body.light-mode .social-links a:hover {
    color: #4a6a4c;
}

.nav-footer {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    align-items: center;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-footer-left {
    color: #a8b5ab;
}

body.light-mode .nav-footer-left {
    color: #5a6b5d;
}

.nav-footer-center {
    text-align: center;
}

/* 3 columns on wide screens */
@media (min-width: 1000px) {
    .cards-grid {
        grid-template-columns: repeat(3, 310px);
    }
}

/* 2 columns on medium screens */
@media (min-width: 700px) and (max-width: 999px) {
    .cards-grid {
        grid-template-columns: repeat(2, 310px);
    }
}

/* 1 column on narrow screens */
@media (max-width: 699px) {
    .cards-grid {
        grid-template-columns: 310px;
        gap: 1.5rem;
    }
    
    h1 {
        font-size: 2rem;
    }

    .nav-footer {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* Webring specific styling */
#data-ring-dot-list {
    text-align: center;
    padding: 1rem;
}

#data-ring-dot-list a {
    color: #e8e2d4 !important;
    text-decoration: underline !important;
    font-size: 0.9rem;
    margin: 0 0.5rem;
    transition: color 0.3s ease;
}

#data-ring-dot-list a:hover {
    color: #ffffff !important;
    text-decoration: none !important;
}

/* Light mode webring styling */
body.light-mode #data-ring-dot-list a {
    color: #2c3e2d !important;
}

body.light-mode #data-ring-dot-list a:hover {
    color: #1a2420 !important;
}
