/* Import fonts */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;600&family=Raleway:wght@300;400;500&display=swap');

/* General styles */
body {
    margin: 0;
    padding: 0;
    font-family: 'Raleway', sans-serif;
    background-color: #1d2327;
    color: #ffffff; /* Pure white base text */
    background-image: linear-gradient(rgba(29, 35, 39, 0.92), rgba(29, 35, 39, 0.95)), url('/Assets/marble.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* Enhanced Quote styling */
.stoic-quote {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.6em;
    line-height: 1.8;
    padding: 2.5em 3em;
    margin: 2.5em 0;
    border-left: 4px solid #deb897; /* Even brighter accent */
    background: linear-gradient(to right, rgba(44, 51, 56, 0.98), rgba(44, 51, 56, 0.92));
    border-radius: 2px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    color: #ffffff;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
}

.stoic-quote:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    background: linear-gradient(to right, rgba(44, 51, 56, 1), rgba(44, 51, 56, 0.95));
    border-left: 4px solid #f0d3b8;
}

.stoic-quote::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 4em;
    color: rgba(166, 125, 93, 0.2);
    font-family: Georgia, serif;
}

.quote-author {
    font-family: 'Raleway', sans-serif;
    font-size: 0.6em;
    text-align: right;
    color: #deb897;
    font-style: italic;
    margin-top: 1.5em;
    letter-spacing: 1px;
    font-weight: 500;
}

/* Header */
.navigation {
    background: linear-gradient(90deg, rgba(29, 35, 39, 0.98), rgba(44, 51, 56, 0.95));
    color: #fafafa;
    padding: 20px 40px;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    border-bottom: 2px solid #deb897;
    box-sizing: border-box;
    flex-wrap: wrap; /* Ensures wrapping for smaller screens */
    
}

.navigation .logo {
    display: flex;
    align-items: center;
    font-size: 28px;
    font-weight: 700;
    color: #deb897;
    flex-grow: 1; /* Allows logo to take up available space */
    font-family: 'Cormorant Garamond', serif;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.navigation .logo img {
    margin-right: 15px;
    width: 45px;
    height: 45px;
    transition: transform 0.4s ease, filter 0.3s ease;
    filter: brightness(1.1) contrast(1.1);
}

.navigation .logo:hover img {
    transform: scale(1.05) rotate(5deg);
    filter: brightness(1.2) contrast(1.2);
}

.navigation .items {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-grow: 2; /* Ensure that items take up remaining space */
    justify-content: end; /* Center the navigation items */
}

.navigation .item {
    font-size: 18px;
    font-weight: 500;
    color: #fafafa; /* Color for anchor links */
    text-decoration: none; /* Remove underline */
    transition: color 0.3s, transform 0.3s;
    font-family: 'Raleway', sans-serif;
    position: relative;
    padding-bottom: 2px;
}

.navigation .item::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #deb897;
    transition: width 0.3s ease;
}

.navigation .item:hover {
    color: #deb897;
    transform: translateY(-2px);
}

.navigation .item:hover::after {
    width: 100%;
}

.navigation .button-container {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 20px;
    flex-grow: 1; /* Allows buttons to align within their space */
}

/* Button Styles */
.navigation .button {
    padding: 12px 26px;
    background: linear-gradient(135deg, #deb897, #c49b76);
    color: white;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    outline: none;
    transition: background 0.3s, transform 0.2s;
    letter-spacing: 1px;
    text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
}

.navigation .button:hover {
    background-color: #e67e22;
    transform: translateY(-2px);
}

.navigation .button.secondary {
    background-color: transparent;
    color: #fafafa;
    border: 2px solid #deb897;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.navigation .button.secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #deb897, #c49b76);
    transition: left 0.3s ease;
    z-index: -1;
}

.navigation .button.secondary:hover::before {
    left: 0;
}

.navigation .button.secondary:hover {
    background-color: #F39C12;
    color: white;
}

/* Container refinements */
.container {
    max-width: 900px;
    height: auto;
    margin: 0 auto;
    position: relative;
    padding: 40px;
    background: linear-gradient(145deg, rgba(35, 41, 45, 0.97), rgba(25, 30, 34, 0.98));
    border-radius: 15px;
    border: 1px solid rgba(166, 125, 93, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    
}

/* Header */
header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    color: #deb897; /* Brightest bronze */
    font-family: 'Cormorant Garamond', serif;
    font-size: 3.5em;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 0.3em;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

header h2 {
    color: #c5c6b6; /* Brighter sage */
    font-family: 'Raleway', sans-serif;
    font-weight: 300;
    letter-spacing: 3px;
    text-transform: uppercase;
    font-size: 1.5em;
    margin: 5px 0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

/* Enhanced Header Styles */
h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2em;
    font-weight: 600;
    color: #deb897;
    text-align: center;
    margin: 2rem 0 1.5rem;
    position: relative;
    padding-bottom: 0.5em;
    letter-spacing: 1.5px;
}

/* h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: linear-gradient(to right, transparent, #deb897, transparent);
} */

/* h2::before {
    content: '•';
    display: block;
    text-align: center;
    color: #deb897;
    font-size: 0.8em;
    margin-bottom: 0.5em;
    opacity: 0.8;
} */

section h2 {
    margin-top: 3rem;
    margin-bottom: 2rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

/* Article */
article h1{
    color: #deb897;
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.2em;
    letter-spacing: 1px;
    margin: 1.5em 0;
    border-bottom: 1px solid rgba(196, 155, 118, 0.4);
    text-align: center;
    padding-bottom: 10px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
    font-weight: 600;
    
}
article h2 {
    font-size: 1.8em;
    margin: 2.5em 0 1.2em;
    color: #deb897;
    position: relative;
    padding-left: 1em;
    padding-right: 1em;
    line-height: 1.4;
}

/* article h2::before {
    content: '"';
    font-family: Georgia, serif;
    position: absolute;
    left: 0;
    top: -0.2em;
    font-size: 1.5em;
    color: rgba(222, 184, 151, 0.3);
} */


/* article h2::after {
    content: '"';
    font-family: Georgia, serif;
    position: absolute;
    right: 0;
    top: -0.2em;
    font-size: 1.5em;
    color: rgba(222, 184, 151, 0.3);
} */

article p {
    font-family: 'Raleway', sans-serif;
    font-weight: 400; /* Slightly bolder weight */
    font-size: 1.1em;
    line-height: 1.9;
    color: #ffffff; /* Pure white for maximum readability */
    margin: 1.5em auto;
    max-width: 800px;
    letter-spacing: 0.3px;
    text-align: justify;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
    padding: 0 1em;
    hyphens: auto;
}

@media (max-width: 480px) {
    article p {
        text-align: left;
        padding: 0;
        font-size: 0.95em;
        line-height: 1.7;
        margin: 1.2em 0;
    }
}

article ul, article ol {
    color: #ffffff;
    margin: 1.5em 0;
    padding-left: 2em;
    font-family: 'Raleway', sans-serif;
}

article li {
    margin: 0.8em 0;
    line-height: 1.6;
    font-size: 1.1em;
}

article strong {
    color: #deb897;
    font-weight: 600;
}

/* Links - Updated styling */
a {
    color: #deb897;
    text-decoration: none;
    border-bottom: none; /* Remove underline */
    font-weight: 500;
    transition: all 0.3s ease;
}

a:hover {
    color: #f0d3b8;
    border-bottom: none;
    text-shadow: 0 0 8px rgba(222, 184, 151, 0.3);
}

/* Navigation link fixes */
.navigation a {
    text-decoration: none;
    border-bottom: none;
}

.navigation a:hover {
    border-bottom: none;
}

/* Footer link fixes */
.footer a {
    text-decoration: none;
    border-bottom: none;
}

.footer a:hover {
    border-bottom: none;
}

/* Subtle animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.container > * {
    animation: fadeIn 0.8s ease-out forwards;
}

/* Footer */
.footer-space {
    height: 120px; /* Match this to the footer height */
    width: 100%;
}

.footer {
    background: linear-gradient(90deg, rgba(29, 35, 39, 0.98), rgba(44, 51, 56, 0.95));
    border-top: 2px solid #deb897;
    color: #fafafa;
    padding: 50px 20px;
    position: relative; /* Make the footer fixed */
    bottom: 0px; /* Position it at the bottom */
    width: 100%; /* Ensure the footer stretches across the entire width */
    display: flex;
    justify-content:space-around;
    align-items: center;
    flex-wrap: auto;
    z-index: 1000; /* Keep it above other content */
    box-sizing: border-box; /* Ensures padding is included in the total width */
}
.footer .logo {
    display: flex;
    align-items: center;
    font-size: 28px;
    font-weight: 700;
    color: #deb897;
    font-family: 'Cormorant Garamond', serif;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.footer .logo img {
    margin-right: 12px;
    width: 45px;
    height: 45px;
}

.footer .items {
    display: flex;
    gap: 48px;
}

.footer .item {
    font-size: 18px;
    font-weight: 500;
    color: #fafafa;
    cursor: pointer;
    transition: color 0.3s, transform 0.2s;
    position: relative;
    padding-bottom: 2px;
}

.footer .item::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #deb897;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.footer .item:hover {
    color: #deb897;
}

.footer .item:hover::after {
    width: 100%;
}

.footer .social-icons {
    display: flex;
    gap: 16px;
}

.footer .icon {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    background-color: #333;
    transition: background-color 0.3s, transform 0.2s;
}

.footer .icon img {
    width: 20px;
}

.footer .icon:hover {
    background-color: #F39C12;
    transform: scale(1.1);
}

.divider {
    width: 100%;
    height: 2px;
    background-color: #333;
    margin-top: 40px;
    opacity: 0.8;
}

/* Utility */
.centered {
    text-align: center;
}

.header-space {
    margin-top: 100px;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger div {
    width: 25px;
    height: 3px;
    background-color: #fafafa;
    margin: 4px 0;
    transition: 0.4s;
}

/* Table Styles */
table {
    width: 100%;
    margin: 2em 0;
    border-collapse: collapse;
    background: linear-gradient(145deg, rgba(35, 41, 45, 0.97), rgba(25, 30, 34, 0.98));
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

thead {
    background: linear-gradient(to right, rgba(44, 51, 56, 0.98), rgba(44, 51, 56, 0.92));
}

th {
    color: #deb897;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2em;
    font-weight: 600;
    text-align: left;
    padding: 1.2em;
    border-bottom: 2px solid rgba(222, 184, 151, 0.3);
}

td {
    color: #ffffff;
    padding: 1em 1.2em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-family: 'Raleway', sans-serif;
    font-size: 1em;
    line-height: 1.6;
}

tr:last-child td {
    border-bottom: none;
}

tr:hover {
    background: linear-gradient(to right, rgba(44, 51, 56, 1), rgba(44, 51, 56, 0.95));
}

@media (max-width: 768px) {
    table {
        font-size: 0.9em;
    }
    
    th, td {
        padding: 0.8em;
    }
}

/* Responsive Styles */
@media (max-width: 768px) {
    .section {
        padding: 80px 20px;
    }

    .images {
        flex-direction: column;
    }

    .image {
        width: 100%;
    }

    .navigation .items,
    .navigation .button-container {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .navigation.active .items,
    .navigation.active .button-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: linear-gradient(90deg, rgba(29, 35, 39, 0.98), rgba(44, 51, 56, 0.95));
        padding: 20px 0;
        gap: 16px;
        z-index: 99;

        border-bottom: 2px solid #deb897;
    }

    .footer .items {
        flex-direction: column;
        gap: 16px;
    }

    .footer {
        flex-direction: column;
        gap: 20px;
    }

    .navigation .button-container {
        flex-direction: column;
        gap: 10px;
    }

    h2 {
        font-size: 1.6em;
        margin: 1.5rem 0 1rem;
    }

    h2::after {
        width: 40px;
    }

    article h2 {
        font-size: 1.4em;
        padding-left: 0.8em;
        padding-right: 0.8em;
    }
}

/* Article Metadata */
.article-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    color: #deb897;
    font-family: 'Raleway', sans-serif;
    font-size: 0.9em;
}

.article-meta i {
    margin-right: 8px;
}

.article-meta a {
    color: #deb897;
    text-decoration: none;
}

.article-meta a:hover {
    color: #f0d3b8;
}

/* Article Navigation - Updated */
.article-navigation {
    margin: 50px 0 30px 0;
    padding: 30px 0;
    border-top: 1px solid rgba(222, 184, 151, 0.2);
    border-bottom: 1px solid rgba(222, 184, 151, 0.2);
}

.nav-links {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

.prev-article,
.next-article {
    color: #deb897;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    padding: 10px 15px;
    border-radius: 4px;
    background: rgba(44, 51, 56, 0.5);
}

.prev-article:hover,
.next-article:hover {
    color: #f0d3b8;
    background: rgba(44, 51, 56, 0.8);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .prev-article,
    .next-article {
        width: 100%;
        justify-content: center;
    }
}

/* Breadcrumb Navigation */
.breadcrumb {
    margin: 20px 0;
    font-family: 'Raleway', sans-serif;
    font-size: 0.9em;
}

.breadcrumb ol {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.breadcrumb li:not(:last-child)::after {
    content: '/';
    margin-left: 8px;
    color: rgba(222, 184, 151, 0.5);
}

.breadcrumb a {
    color: #deb897;
    text-decoration: none;
}

.breadcrumb a:hover {
    color: #f0d3b8;
}

.breadcrumb li:last-child {
    color: #ffffff;
}

@media (max-width: 768px) {
    .article-meta {
        flex-direction: column;
        gap: 10px;
    }

    .nav-links {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 480px) {
    article h1, article h2 {
        font-size: 1.4em; /* Reduces heading font size for small screens */
    }

    article p {
        font-size: 0.9em; /* Reduces paragraph font size */
        line-height: 1.5; /* Slightly tighter line spacing */
        text-align: left; /* Aligns text for better readability */
    }

    .container {
        padding: 15px; /* Less padding for mobile to make use of the screen space */
    }
}

/* Profile Styles */
.profile-container {
    position: relative;
    display: inline-block;
}

.profile-photo {
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-left: 10px;
    display: none;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.profile-photo.visible {
    display: block;
    opacity: 1;
}

#loginBtn {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

#loginBtn.visible {
    display: inline-block;
    opacity: 1;
}

.dropdown-menu {
    display: none;
    position: absolute;
    right: 0;
    top: 45px;
    background-color: white;
    min-width: 200px;
    padding: 8px 0;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    border-radius: 4px;
}


.dropdown-menu.show {
    display: block;
}

.user-info {
    padding: 12px 16px;
    border-bottom: 1px solid #eee;
    margin-bottom: 8px;
}

.user-name {
    font-weight: bold;
    margin-bottom: 4px;
}

.user-email {
    font-size: 0.9em;
    color: #666;
}

.dropdown-menu button {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: none;
    cursor: pointer;
    text-align: left;
}

.dropdown-menu button i {
    width: 16px;
    text-align: center;
}

.dropdown-menu button:hover {
    background-color: #f1f1f1;
}

.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #333;
    color: white;
    padding: 12px 24px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    z-index: 1000;
}

.toast.success {
    background: #4CAF50;
}

.toast.show {
    opacity: 1;
}

/* Dark mode support */
body.dark-mode .dropdown-menu {
    background-color: #333;
    color: #fff;
    border: 1px solid #444;
}

body.dark-mode .dropdown-menu button:hover {
    background: #444;
}

/* Articles Section Styling */
.articles-section {
    padding: 2rem 0;
    background: transparent;
}

.search-filter-container {
    background: linear-gradient(145deg, rgba(35, 41, 45, 0.97), rgba(25, 30, 34, 0.98));
    padding: 2rem;
    border-radius: 10px;
    border: 1px solid rgba(222, 184, 151, 0.1);
    margin-bottom: 2rem;
}

.search-bar {
    background: rgba(29, 35, 39, 0.95);
    border: 1px solid rgba(222, 184, 151, 0.2);
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 6px;
    width: 100%;
    max-width: 400px;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.search-bar:focus {
    border-color: #deb897;
    outline: none;
    box-shadow: 0 0 10px rgba(222, 184, 151, 0.1);
}

.search-bar::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.category-filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.category-filter {
    background: transparent;
    border: 1px solid #deb897;
    color: #deb897;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-filter:hover {
    background: rgba(222, 184, 151, 0.1);
    transform: translateY(-2px);
}

.category-filter.active {
    background: #deb897;
    color: #1d2327;
}

/* Article Cards Styling */
.article-card {
    background: linear-gradient(145deg, rgba(35, 41, 45, 0.97), rgba(25, 30, 34, 0.98));
    border: 1px solid rgba(222, 184, 151, 0.1);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    border-color: rgba(222, 184, 151, 0.3);
}

.article-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid rgba(222, 184, 151, 0.1);
}

.article-title {
    color: #deb897;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.5em;
    margin: 1rem;
    font-weight: 600;
}

.article-excerpt {
    color: rgba(255, 255, 255, 0.8);
    font-family: 'Raleway', sans-serif;
    font-size: 0.9em;
    line-height: 1.6;
    margin: 0 1rem 1rem;
}

/* Articles Container Grid */
.articles-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 1rem 0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .search-filter-container {
        padding: 1rem;
    }
    
    .category-filters {
        justify-content: center;
    }
    
    .articles-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}
