/* ==========================================================================
   Base Styles
   ========================================================================== */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f2ee;
    padding: 0;
    margin: 0;
    line-height: 1.6;
}

/* Prevent body scroll when modal is open */
body.modal-open {
    overflow: hidden;
}

/* ==========================================================================
   Layout Components
   ========================================================================== */

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

.content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */

.header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px 0;
    margin-bottom: 20px;
    background-color: #f5f2ee;
}

.logo {
    display: block;
    text-decoration: none;
}

.logo-img,
.logo-icon {
    height: 110px;
    width: auto;
    display: block;
}

.logo-icon img {
    width: 100%;
    height: auto;
    display: block;
}

.nav-links {
    text-align: center;
    margin: 20px 0 40px 0;
    padding: 0;
}

.nav-links a {
    color: #666;
    text-decoration: none;
    font-size: 16px;
    margin: 0 15px;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: #333;
    text-decoration: underline;
}

.nav-links a.active {
    color: #333;
    font-weight: 600;
}

.nav-links span {
    color: #ccc;
    margin: 0 5px;
}

/* ==========================================================================
   Typography
   ========================================================================== */

h1 {
    text-align: center;
    font-size: 48px;
    font-weight: 500;
    color: #333;
    margin-bottom: 16px;
    letter-spacing: -1px;
    font-family: "Newsreader", serif;
    font-optical-sizing: auto;
}

.subtitle {
    text-align: center;
    font-size: 18px;
    color: #666;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.3;
    font-family: "Newsreader", serif;
    font-optical-sizing: auto;
    font-weight: 500;
}

/* Kenning Counter */
h1 .kenning-counter {
    display: none;
    /* Styles preserved for when/if re-enabled
    display: inline-block;
    background-color: #e8e8e8;
    color: #666;
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin-left: 8px;
    vertical-align: super;
    position: relative;
    top: -8px;
    */
}

/* ==========================================================================
   Artist Filter
   ========================================================================== */

/* ==========================================================================
   Kenning of the Day
   ========================================================================== */

.kenning-of-day {
    max-width: 1400px;
    margin: 30px auto 40px;
    padding: 0 20px;
    position: relative;
}

.kenning-of-day-badge {
    display: inline-block;
    background: transparent;
    color: #333;
    padding: 0;
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 20px;
    font-family: "Newsreader", serif;
    border-bottom: 2px solid #333;
    padding-bottom: 4px;
}

.kenning-of-day-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .kenning-of-day-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.artist-filter {
    text-align: center;
    margin: 30px auto 20px;
    padding: 0 20px;
}

.artist-button {
    background-color: #fff;
    border: 2px solid #ddd;
    border-radius: 25px;
    padding: 10px 24px;
    margin: 5px 8px;
    font-size: 15px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}

.artist-button:hover {
    border-color: #333;
    color: #333;
    background-color: #f9f9f9;
}

.artist-button.active {
    background-color: #333;
    border-color: #333;
    color: #fff;
}

.favorites-button-filter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: top;
}

.favorites-button-filter svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.favorites-count {
    font-weight: 600;
    margin-left: 4px;
}

/* Export Favorites */
.export-favorites {
    text-align: center;
    margin: 30px auto 40px;
    padding: 0 20px;
    position: relative;
}

.export-button {
    background-color: transparent;
    color: #333;
    border: 2px solid #333;
    border-radius: 6px;
    padding: 12px 28px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-family: "Newsreader", serif;
}

.export-button:hover {
    background-color: #e74c3c;
    border-color: #e74c3c;
    color: white;
}

.export-button svg {
    margin-right: 8px;
}

.export-tooltip {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 13px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    margin-top: 8px;
}

.export-tooltip.show {
    opacity: 1;
}

/* ==========================================================================
   Search Bar
   ========================================================================== */

/* Controls Row - Unified Search, Random, Favorites */
.controls-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 30px auto 20px;
    padding: 0 20px;
    max-width: 1000px;
    flex-wrap: wrap;
}

/* Base style for all control buttons */
.control-button {
    background-color: #333;
    color: white;
    border: none;
    border-radius: 20px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    font-family: "Newsreader", serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.control-button:hover {
    background-color: #555;
    transform: scale(1.05);
}

.control-button svg {
    flex-shrink: 0;
}

/* Search wrapper and input */
.search-wrapper {
    position: relative;
    flex: 0 0 auto;
    width: 260px;
    transition: all 0.3s ease;
}

.search-wrapper:focus-within {
    width: 500px;
}

.search-button {
    width: 100%;
    padding: 10px 38px;
    text-align: left;
    background-color: #fff;
    color: #333;
    border: 2px solid #ddd;
}

.search-button:hover {
    background-color: #f5f5f5;
}

.search-button::placeholder {
    color: rgba(51, 51, 51, 0.5);
}

.search-button:focus {
    outline: 2px solid #333;
    outline-offset: 2px;
    background-color: #fff;
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: #333;
    opacity: 0.7;
    z-index: 1;
}

.clear-search-inline {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.1);
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease;
    color: #333;
}

.clear-search-inline:hover {
    background-color: rgba(0, 0, 0, 0.2);
}

.clear-search-inline svg {
    display: block;
}

/* Favorites control button specific styling */
.favorites-control-button.active {
    background-color: #e74c3c;
}

.favorites-control-button.active:hover {
    background-color: #c0392b;
}

.favorites-count {
    font-size: 12px;
    opacity: 0.9;
}

/* Hide random button */
#randomButton {
    display: none;
}

@media (max-width: 768px) {
    .controls-row {
        flex-direction: column;
        gap: 10px;
    }

    .search-wrapper {
        max-width: 100%;
        width: 100%;
    }

    .search-wrapper:focus-within {
        max-width: 100%;
    }

    .control-button:hover {
        transform: scale(1.05);
    }
}

/* ==========================================================================
   Tag Cloud
   ========================================================================== */

.tag-cloud {
    text-align: center;
    margin: 20px auto 40px;
    max-width: 900px;
    padding: 0 20px;
}

.tag-item {
    display: inline-block;
    font-size: 14px;
    font-family: "Newsreader", serif;
    font-optical-sizing: auto;
    font-weight: 400;
    color: #666;
    padding: 4px 12px;
    margin: 4px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: transparent;
}

.tag-item:hover {
    border-color: #999;
    background-color: #f9f9f9;
    color: #333;
}

.tag-item.active {
    background-color: #333;
    color: #fff;
    border-color: #333;
}

.tag-item.show-all {
    font-style: italic;
    border-style: dashed;
}

.tag-show-more-pill {
    font-style: italic;
    background-color: #f5f5f5;
    border-color: #999;
}

.tag-show-more-pill:hover {
    background-color: #e0e0e0;
    border-color: #666;
}

/* ==========================================================================
   Grid Layout (Gallery)
   ========================================================================== */

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 32px;
    margin-bottom: 48px;
}

/* Limit to 3 columns max */
@media (min-width: 1400px) {
    .grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    border: 1px solid #f0f0f0;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.card-image-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio for larger cards */
    overflow: hidden;
    background: #f0f0f0;
}

.card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

/* Card Header with Title and Favorite Button */
.card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    flex: 1;
}

/* Favorite Heart Button */
.favorite-button {
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    padding: 4px;
    flex-shrink: 0;
}

.favorite-button:hover {
    transform: scale(1.15);
}

.favorite-button svg {
    width: 24px;
    height: 24px;
    transition: all 0.2s ease;
}

.favorite-button.active svg {
    fill: #e74c3c;
    stroke: #e74c3c;
}

.favorite-button:not(.active) svg {
    fill: none;
    stroke: #666;
}

.favorite-button:hover:not(.active) svg {
    stroke: #e74c3c;
}

/* Favorite animation */
@keyframes favoritePopIn {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

.favorite-button.active {
    animation: favoritePopIn 0.3s ease;
}

.card:hover .card-image {
    transform: scale(1.05);
}

.card-content {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 21px;
    font-weight: 500;
    color: #333;
    line-height: 1.4;
    margin: 0;
    flex: 1;
    font-family: "Newsreader", serif;
    font-optical-sizing: auto;
}

/* ==========================================================================
   Share Buttons
   ========================================================================== */

.share-button {
    display: none; /* Temporarily hidden */
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: #e0e0e0;
    color: #666;
    text-decoration: none;
    transition: background-color 0.2s ease;
    margin-left: 12px;
    flex-shrink: 0;
}

.share-button:hover {
    background-color: #d0d0d0;
}

.share-button svg {
    width: 14px;
    height: 14px;
    fill: #666;
}

/* ==========================================================================
   Modal
   ========================================================================== */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #f5f2ee;
    z-index: 1000;
    overflow: auto;
}

.modal.active {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.modal-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    box-sizing: border-box;
}

.modal-image-container {
    width: 90%;
    max-width: 1200px;
    max-height: 75%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 40px;
    position: relative;
}

.modal-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.modal-caption {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    text-align: center;
    line-height: 1.4;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    font-family: "Newsreader", serif;
    font-optical-sizing: auto;
}

.modal-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.modal-actions > * {
    display: flex;
    align-items: center;
}

.modal-logo {
    height: 40px;
    width: auto;
}

.modal-share-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #000;
    color: #fff;
    text-decoration: none;
    transition: background-color 0.2s ease;
    border: none;
    cursor: pointer;
    position: relative;
}

.modal-share-button:hover {
    background-color: #333;
}

.modal-share-button svg {
    width: 18px;
    height: 18px;
    fill: #fff;
}

/* Copy button tooltip */
.copy-tooltip {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-bottom: 8px;
    padding: 6px 12px;
    background-color: #333;
    color: white;
    font-size: 12px;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    pointer-events: none;
}

.copy-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #333;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: none;
    background-color: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    outline: none;
    padding: 0;
}

.modal-close:hover::before,
.modal-close:hover::after {
    background-color: #666;
}

.modal-close::before,
.modal-close::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 3px;
    background-color: #333;
    transition: background-color 0.2s ease;
}

.modal-close::before {
    transform: rotate(45deg);
}

.modal-close::after {
    transform: rotate(-45deg);
}

/* Modal Navigation Arrows */
.modal-nav {
    position: fixed;
    top: 40%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    background: none;
    background-color: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    outline: none;
    padding: 0;
}

.modal-nav:hover svg path {
    fill: #666;
}

.modal-nav svg {
    width: 50px;
    height: 50px;
    display: block;
}

.modal-nav-prev {
    left: 20px;
}

.modal-nav-next {
    right: 20px;
}

/* Hide navigation arrows on mobile devices */
@media (max-width: 768px) {
    .modal-nav {
        display: none !important;
    }

    /* Adjust modal image container on mobile */
    .modal-image-container {
        width: 100%;
        max-width: none;
    }
}

/* Related Kennings in Modal */
.related-kennings {
    width: 100%;
    max-width: 1200px;
    margin: 40px auto 20px;
    padding: 0 20px;
}

.related-title {
    font-family: "Newsreader", serif;
    font-size: 20px;
    font-weight: 500;
    color: #666;
    text-align: center;
    margin-bottom: 20px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    max-width: 900px;
    margin: 0 auto;
}

.related-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid #f0f0f0;
}

.related-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: #333;
}

.related-card-image {
    width: 100%;
    aspect-ratio: 2 / 1;
    object-fit: cover;
}

.related-card-caption {
    padding: 12px;
    font-family: "Newsreader", serif;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    text-align: center;
    line-height: 1.3;
}

@media (max-width: 768px) {
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .related-card-caption {
        font-size: 12px;
        padding: 8px;
    }
}

/* ==========================================================================
   Prose Content (About Pages)
   ========================================================================== */

.prose {
    font-size: 18px;
    line-height: 1.8;
    color: #333;
    margin-bottom: 32px;
}

.prose p {
    margin-bottom: 24px;
}

.prose ul {
    margin: 24px 0;
    padding-left: 40px;
}

.prose ul li {
    margin-bottom: 12px;
    font-size: 18px;
    line-height: 1.8;
    color: #333;
}

.prose h2 {
    font-family: "Newsreader", serif;
    font-size: 32px;
    font-weight: 500;
    margin-top: 48px;
    margin-bottom: 24px;
    color: #333;
    letter-spacing: -0.5px;
    font-optical-sizing: auto;
}

.prose h3 {
    font-family: "Newsreader", serif;
    font-size: 24px;
    font-weight: 500;
    margin-top: 32px;
    margin-bottom: 16px;
    color: #333;
    letter-spacing: -0.3px;
    font-optical-sizing: auto;
}

/* ==========================================================================
   Special Content Blocks
   ========================================================================== */

/* Mission Image (About StoryLeaf) */
.mission-image {
    margin: 30px 0;
    width: 100%;
    aspect-ratio: 3 / 1;
    overflow: hidden;
    border-radius: 8px;
}

.mission-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Kenning Examples (About Kennings) */
.kenning-example {
    background-color: #fff;
    border-left: 4px solid #333;
    margin: 24px 0;
    display: flex;
    align-items: stretch;
    overflow: hidden;
    min-height: 100px;
}

.kenning-text {
    flex: 1;
    font-style: italic;
    padding: 20px 24px;
}

.kenning-example .original {
    font-weight: 600;
    color: #1a1a1a;
}

.kenning-example .translation {
    color: #666;
    font-size: 16px;
    margin-top: 8px;
}

.kenning-image {
    width: 200px;
    flex-shrink: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Historical Image (About Kennings) */
.historical-image {
    margin: 30px auto;
    width: 40%;
}

.historical-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

.historical-image .caption {
    font-style: italic;
    color: #666;
    font-size: 14px;
    line-height: 1.4;
    text-align: center;
    margin-top: 12px;
}

/* Style Note (About Illustrations) */
.style-note {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    padding: 24px;
    margin: 32px 0;
    border-radius: 8px;
}

.style-note h4 {
    font-family: 'Newsreader', serif;
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
    color: #1a1a1a;
}

.style-note p {
    font-size: 16px;
    margin-bottom: 12px;
}

.style-note p:last-child {
    margin-bottom: 0;
}

/* Embedding Image (About Illustrations) */
.embedding-image {
    margin: 30px 0;
}

.embedding-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

/* Artist Profiles (About Illustrations) */
.artist-profiles {
    display: flex;
    gap: 40px;
    margin: 40px -20px;
    justify-content: space-between;
    flex-wrap: wrap;
}

.artist-profile {
    text-align: center;
    flex: 1;
    min-width: 300px;
}

.artist-profile img {
    width: 100%;
    max-width: 400px;
    height: auto;
    aspect-ratio: 1;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 16px;
}

.artist-profile h4 {
    font-family: "Newsreader", serif;
    font-size: 20px;
    font-weight: 500;
    color: #333;
    margin-bottom: 8px;
}

.artist-profile p {
    font-size: 14px;
    color: #666;
    line-height: 1.4;
    margin: 0 auto;
    max-width: 300px;
}

/* ==========================================================================
   Utility Components
   ========================================================================== */

/* Back to Gallery Link */
.back-to-gallery {
    text-align: center;
    margin-top: 64px;
    margin-bottom: 48px;
}

.back-to-gallery a {
    display: inline-block;
    padding: 12px 24px;
    background-color: #333;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.back-to-gallery a:hover {
    background-color: #555;
}

/* Loading State */
.loading {
    text-align: center;
    padding: 60px 20px;
    font-size: 18px;
    color: #666;
}

/* Error State */
.error {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: #d32f2f;
    font-size: 18px;
    width: 100%;
}

/* Image Loading Skeleton */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Load More Button */
.load-more {
    text-align: center;
    margin: 40px 0;
}

.load-more button {
    padding: 12px 32px;
    font-size: 16px;
    font-weight: 600;
    background-color: #111;
    color: white;
    border: none;
    border-radius: 24px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.load-more button:hover {
    background-color: #333;
}

.load-more button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* ==========================================================================
   Share Page Specific Styles
   ========================================================================== */

/* Body modification for share pages */
body.share-page {
    height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Share page header */
.share-page .header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    margin-bottom: 0;
}

.share-page .logo {
    height: 50px;
    width: auto;
}

.view-gallery {
    padding: 10px 20px;
    background-color: #111;
    color: white;
    text-decoration: none;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.2s ease;
}

.view-gallery:hover {
    background-color: #333;
}

/* Share page main content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.share-page .image-container {
    width: 90%;
    max-width: 900px;
    margin-bottom: 30px;
}

.share-page .kenning-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.share-page .caption {
    font-size: 32px;
    font-weight: 600;
    color: #333;
    text-align: center;
    line-height: 1.4;
    letter-spacing: -0.02em;
    margin-bottom: 30px;
    font-family: "Newsreader", serif;
    font-optical-sizing: auto;
}

.share-page .actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.share-page .actions img {
    height: 40px;
    width: auto;
}

.share-page .share-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #000;
    color: #fff;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.share-page .share-button:hover {
    background-color: #333;
}

.share-page .share-button svg {
    width: 18px;
    height: 18px;
    fill: #fff;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    /* Typography */
    h1 {
        font-size: 36px;
    }
    
    .subtitle {
        font-size: 18px;
    }
    
    .prose {
        font-size: 16px;
    }
    
    .prose h2 {
        font-size: 28px;
    }
    
    .prose h3 {
        font-size: 20px;
    }
    
    /* Grid */
    .grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    /* Cards */
    .card-content {
        padding: 20px 24px 24px;
    }
    
    .card-title {
        font-size: 20px;
    }
    
    /* Kenning Examples */
    .kenning-example {
        flex-direction: column;
    }
    
    .kenning-image {
        width: 100%;
        height: 150px;
    }
    
    /* Share Page */
    .share-page .header {
        flex-direction: column;
        gap: 20px;
    }
    
    .share-page .image-container {
        width: 95%;
    }
    
    .share-page .caption {
        font-size: 24px;
        padding: 0 20px;
    }
    
    .share-page .actions {
        flex-direction: column;
    }
    
    /* Tag Cloud */
    .tag-cloud {
        margin: 20px auto 30px;
    }

    .tag-item {
        font-size: 12px;
        padding: 3px 8px;
        margin: 3px;
    }
}