html {
    scrollbar-gutter: stable;
}

body {
    font-family: 'Inter', sans-serif;
    background: url('../images/background.jpg') no-repeat center center fixed;
    background-size: cover;
    color: #E5E7EB;
}

.hidden {
    display: none !important;
}



.main-content-wrapper {
    padding-top: 100px;
    z-index: 1;
}

nav.fixed-nav {
    position: fixed;
    top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 50;
}

.backdrop-blur-lg {
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.nav-link {
    transition: transform 0.2s ease, color 0.2s ease;
}

.nav-link:hover {
    transform: scale(1.1);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid rgba(255, 255, 255, 0.1);
}

.content-section {
    display: none;
}

.content-section.active {
    display: block;
    animation: fadeInUp 0.6s ease-out forwards;
}

.card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.card:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-5px);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#home-title::after {
    content: '|';
    animation: blink 0.7s infinite;
    font-weight: 400;
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

.cta-button {
    display: inline-block;
    background-color: #2563EB;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.cta-button:hover {
    background-color: #1D4ED8;
    transform: translateY(-2px);
}

.skill-badge {
    background: rgba(255, 255, 255, 0.1);
    color: #D1D5DB;
}

.modal {
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal.hidden {
    opacity: 0;
    visibility: hidden;
}

.modal-content {
    transition: transform 0.3s ease;
}

.modal.hidden .modal-content {
    transform: scale(0.95);
}

.prose-custom {
    color: #FFFFFF;
}

.prose-custom h1,
.prose-custom h2,
.prose-custom h3,
.prose-custom strong {
    color: #FFF;
}

.prose-custom a {
    color: #60A5FA;
}

.prose-custom code {
    color: #FBBF24;
}

.prose-custom pre {
    background-color: rgba(0, 0, 0, 0.3);
}

.prose-custom blockquote {
    border-left-color: #6B7280;
    color: #9CA3AF;
}

/* --- ✨ Card Wall Styles --- */
#polaroid-wall {
    perspective: 1000px;
    grid-template-columns: repeat(1, 1fr);
}

@media (min-width: 640px) {
    #polaroid-wall {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1024px) {
    #polaroid-wall {
        grid-template-columns: repeat(3, 1fr);
    }
}

.polaroid {
    padding: 1rem;
    border-radius: 4px;
    position: relative;
    animation: dropIn 0.5s ease-out forwards;
    transform-style: preserve-3d;
    overflow-wrap: break-word;
    min-height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.polaroid-content {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.polaroid-caption {
    text-align: right;
    font-size: 1.1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-top: 0.5rem;
}

@keyframes dropIn {
    from {
        opacity: 0;
        transform: translateY(-50px) rotateX(-90deg);
    }

    to {
        opacity: 1;
        transform: translateY(0) rotateX(0deg);
    }
}

/* --- THEME DEFINITIONS --- */
.theme-polaroid {
    background-color: #f4f4f4;
    padding-bottom: 3.5rem;
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 6px 20px rgba(0, 0, 0, 0.19);
}

.theme-polaroid .polaroid-content {
    background-color: #333;
    color: #e5e7eb;
    min-height: 100px;
    border: 1px solid #444;
}

.theme-polaroid .polaroid-caption {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    text-align: center;
    font-family: 'Caveat', cursive;
    font-size: 1.25rem;
    color: #222;
    font-weight: bold;
}

.theme-notebook {
    background-color: #F7F5E9;
    color: #333;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    border: 1px solid #ddd;
    background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 23px, #9DD0E7 24px);
    position: relative;
}

.theme-notebook::before {
    content: '';
    position: absolute;
    top: 0;
    left: 28px;
    bottom: 0;
    width: 2px;
    background-color: #E98A88;
}

.theme-notebook .polaroid-content {
    color: #1E40AF;
    padding: 10px 10px 10px 40px;
    font-size: 1rem;
    align-items: start;
    justify-content: start;
    text-align: left;
}

.theme-notebook .polaroid-caption {
    font-family: 'Caveat', cursive;
    color: #DC2626;
    padding-right: 10px;
}

.theme-terminal {
    background-color: #1E293B;
    color: #34D399;
    font-family: 'VT323', monospace;
    border: 1px solid #34D399;
    box-shadow: 0 0 10px rgba(52, 211, 153, 0.3);
    border-radius: 8px;
}

.theme-terminal .polaroid-content {
    font-size: 1.2rem;
    align-items: start;
    justify-content: start;
    text-align: left;
    padding-left: 0.5rem;
}

.theme-terminal .polaroid-caption {
    font-size: 1.2rem;
    color: #A78BFA;
    padding-right: 0.5rem;
}

.theme-terminal .polaroid-caption::before {
    content: '~> ';
}

/* --- ✨ NEW THEMES ✨ --- */
.theme-minimal-dark {
    background-color: #1f2937;
    border: 1px solid #4b5563;
    color: #d1d5db;
    border-radius: 8px;
}

.theme-minimal-dark .polaroid-content {
    text-align: left;
    justify-content: flex-start;
}

.theme-minimal-dark .polaroid-caption {
    color: #6b7280;
}

.theme-post-it {
    background-color: #fef08a;
    color: #1e2937;
    font-family: 'Caveat', cursive;
    box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2);
}

.theme-post-it .polaroid-content {
    font-size: 1.3rem;
}

.theme-post-it .polaroid-caption {
    color: #475569;
    font-size: 1.2rem;
}

.theme-blueprint {
    background-color: #1e40af;
    color: #fff;
    border: 2px solid #60a5fa;
    background-image: linear-gradient(rgba(255, 255, 255, 0.1) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 20px 20px;
    font-family: 'VT323', monospace;
}

.theme-blueprint .polaroid-content {
    font-size: 1.1rem;
    text-align: left;
    justify-content: flex-start;
}

.theme-blueprint .polaroid-caption {
    color: #93c5fd;
}

.theme-newspaper {
    background-color: #f3eace;
    color: #333;
    font-family: 'Merriweather', serif;
    border: 1px solid #dcd3b8;
}

.theme-newspaper .polaroid-content {
    text-align: justify;
    font-size: 0.9rem;
}

.theme-newspaper .polaroid-caption {
    font-style: italic;
    color: #555;
}

.theme-chalkboard {
    background-color: #394a4f;
    color: #f1f1f1;
    font-family: 'Caveat', cursive;
    border: 5px solid #8c6a46;
    border-radius: 10px;
    box-shadow: inset 0 0 10px #000;
}

.theme-chalkboard .polaroid-content {
    font-size: 1.4rem;
}

.theme-chalkboard .polaroid-caption {
    color: #ccc;
    font-size: 1.2rem;
}

.theme-sunset-grad {
    background-image: linear-gradient(45deg, #833ab4, #fd1d1d, #fcb045);
    color: white;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.theme-sunset-grad .polaroid-content {
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.4);
}

.theme-sunset-grad .polaroid-caption {
    color: #eee;
    font-style: italic;
}

.theme-highlighter {
    background-color: #fff;
    border: 1px solid #ddd;
}

.theme-highlighter .polaroid-content {
    background-color: #fef08a;
    color: #1f2937;
    padding: 0.5rem;
}

.theme-highlighter .polaroid-caption {
    color: #6b7280;
}


/* --- Theme Selector Styles --- */
.theme-preview {
    height: 60px;
    width: 80px;
    border: 3px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.theme-preview:hover {
    transform: scale(1.05);
}

.theme-preview.active-theme {
    border-color: #3B82F6;
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

#card-preview-container.hidden {
    display: none;
}

#card-preview-container {
    transition: opacity 0.3s ease;
}