:root {
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
    --premium-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #f8fafc;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    color: #1e293b;
}

.font-outfit { font-family: 'Outfit', sans-serif; }

.glass-nav {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
}

.glass-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
}

.premium-text-gradient {
    background: var(--premium-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-link-premium {
    position: relative;
    transition: all 0.3s ease;
}

.nav-link-premium::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--premium-gradient);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link-premium:hover::after, .nav-link-premium.active-nav::after {
    width: 80%;
}

/* More Tools Dropdown */
.more-tools-dropdown {
    position: relative;
}
.more-tools-trigger {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    user-select: none;
}
.more-tools-trigger .chevron-icon {
    transition: transform 0.3s ease;
    font-size: 0.65rem;
}
.more-tools-dropdown.open .chevron-icon {
    transform: rotate(180deg);
}
.more-tools-menu {
    position: absolute;
    top: calc(100% + 0.75rem);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    min-width: 240px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 1rem;
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0,0,0,0.03);
    padding: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
}
.more-tools-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.95);
    border-left: 1px solid rgba(226, 232, 240, 0.8);
    border-top: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 2px 0 0 0;
}
.more-tools-dropdown.open .more-tools-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.more-tools-menu a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem 1rem;
    border-radius: 0.65rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    text-decoration: none;
    transition: all 0.2s ease;
}
.more-tools-menu a:hover {
    background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(168,85,247,0.08));
    color: #4f46e5;
    transform: translateX(2px);
}
.more-tools-menu a .tool-icon {
    width: 32px;
    height: 32px;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    flex-shrink: 0;
}
.more-tools-menu a .tool-desc {
    font-size: 0.7rem;
    font-weight: 400;
    color: #9ca3af;
    margin-top: 1px;
}

/* Mobile submenu */
.mobile-submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
}
.mobile-submenu.open {
    max-height: 300px;
}

.message-toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 1rem 1.5rem;
    border-radius: 1rem;
    color: white;
    z-index: 9999;
    opacity: 0;
    transform: translateY(1rem);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

.message-toast.show {
    opacity: 1;
    transform: translateY(0);
}

.success-toast { background: linear-gradient(135deg, #10b981, #059669); }
.error-toast { background: linear-gradient(135deg, #ef4444, #dc2626); }
.info-toast { background: linear-gradient(135deg, #3b82f6, #2563eb); }

.item-name {
    font-size: 0.95rem;
    font-weight: 700 !important;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Blog & Article Typography */
.prose-blog {
    color: #374151;
    line-height: 1.8;
    font-size: 1.125rem;
}
.prose-blog h2 {
    font-size: 1.875rem;
    font-weight: 800;
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
    color: #111827;
    letter-spacing: -0.025em;
}
.prose-blog h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #1f2937;
}
.prose-blog p {
    margin-bottom: 1.5rem;
}
.prose-blog ul, .prose-blog ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}
.prose-blog li {
    margin-bottom: 0.5rem;
}
.prose-blog blockquote {
    border-left: 4px solid #6366f1;
    padding-left: 1.5rem;
    font-style: italic;
    color: #4b5563;
    margin: 2rem 0;
}
.prose-blog img {
    border-radius: 1.5rem;
    margin: 2.5rem 0;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

/* Responsive Tweaks */

@media (max-width: 640px) {
    .glass-card {
        padding: 1rem !important;
    }
    .item-name {
        font-size: 0.85rem !important;
        max-width: 140px; /* Limit width on mobile to ensure buttons fit */
    }
    .item-quantity {
        width: 4rem !important;
        font-size: 0.75rem !important;
        padding-left: 0.25rem !important;
        padding-right: 0.25rem !important;
    }
    .remove-btn {
        width: 2.25rem !important;
        height: 2.25rem !important;
    }
    .item-checkbox {
        width: 1.75rem !important;
        height: 1.75rem !important;
    }
    .category-header span {
        font-size: 8px !important;
        letter-spacing: 0.1em !important;
    }
    .item-handle, .category-handle {
        font-size: 0.85rem !important;
        margin-right: 0.5rem !important;
    }
    /* Global padding overrides for hero sections and cards */
    .p-8 { padding: 1.25rem !important; }
    .p-12 { padding: 1.5rem !important; }
    .p-20 { padding: 2rem !important; }
    .mb-12 { margin-bottom: 1.5rem !important; }
    .gap-8 { gap: 1rem !important; }
    .gap-6 { gap: 0.75rem !important; }
    .gap-4 { gap: 0.5rem !important; }

    /* Blog Tweaks */
    .prose-blog {
        font-size: 1rem;
    }
    .prose-blog h2 { font-size: 1.5rem; }
    .prose-blog h3 { font-size: 1.25rem; }
}
