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

:root {
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 20px;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 20px rgba(168, 85, 247, 0.3);
    --transition: all 0.2s ease;
    --transition-slow: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--background);
    color: var(--foreground);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Animated background elements */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255, 107, 157, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(180, 78, 205, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(165, 94, 234, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
    animation: backgroundFloat 20s ease-in-out infinite;
    transition: opacity 0.4s ease;
}

/* Light theme background overlay */
body.light::before {
    background: 
        radial-gradient(circle at 20% 80%, rgba(244, 114, 182, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(52, 211, 153, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(192, 132, 252, 0.06) 0%, transparent 50%);
}

@keyframes backgroundFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-10px) rotate(1deg); }
    66% { transform: translateY(5px) rotate(-1deg); }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* Header Styles */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 0;
    background: url('../images/Bdsm_test_logo_wip_1.png') center/cover no-repeat;
    aspect-ratio: 3 / 1;
    width: 100%;
    border-radius: var(--radius-xl);
    color: white;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    animation: headerGlow 3s ease-in-out infinite alternate;
    transition: all 0.4s ease;
}

@keyframes headerGlow {
    0% { box-shadow: var(--shadow-xl), 0 0 30px rgba(255, 107, 157, 0.3); }
    100% { box-shadow: var(--shadow-xl), 0 0 50px rgba(255, 107, 157, 0.5); }
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: headerShine 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 2;
}

@keyframes headerShine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    50% { transform: translateX(100%) translateY(100%) rotate(45deg); }
    100% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
}

.header-content {
    position: relative;
    z-index: 3;
    padding: 40px;
}

.header-content h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    animation: titlePulse 2s ease-in-out infinite alternate;
}

@keyframes titlePulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.02); }
}

.header-content p {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 600px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.header-graphic {
    display: flex;
    gap: 12px;
    position: relative;
    z-index: 3;
    padding: 40px;
}

.graphic-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    animation: circleFloat 3s ease-in-out infinite;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.graphic-circle:nth-child(1) { animation-delay: 0s; }
.graphic-circle:nth-child(2) { animation-delay: 0.5s; }
.graphic-circle:nth-child(3) { animation-delay: 1s; }

@keyframes circleFloat {
    0%, 100% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-10px) scale(1.05); }
}

.sticky-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    margin: 0 -20px 30px -20px;
    border-bottom: 1px solid var(--border);
    top: 0;
    background: var(--sticky-header-bg);
    z-index: 100;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: var(--radius-lg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Sticky header when scrolled */
.sticky-header.scrolled {
    background: var(--sticky-header-bg-scrolled);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

/* Light theme sticky header adjustments */
body.light .sticky-header {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

body.light .sticky-header.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.sticky-header:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.2);
}

.sticky-header .header-content h1 {
    font-size: 1.8rem;
    margin-bottom: 5px;
}

.sticky-header .header-content p {
    font-size: 1rem;
    color: var(--muted-foreground);
}

.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* Card Styles */
.card {
    background: var(--card);
    border-radius: var(--radius-xl);
    padding: 24px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 157, 0.1), transparent);
    transition: left 0.5s ease;
}

.card:hover::before {
    left: 100%;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
}

.card-header {
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.card-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--foreground);
}

.card-header p {
    color: var(--muted-foreground);
    font-size: 0.95rem;
}

.card-content {
    padding: 10px 0;
    position: relative;
    z-index: 1;
}

/* Button Styles */
.btn {
    padding: 12px 20px;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition-slow);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transition: width 0.3s ease, height 0.3s ease;
    transform: translate(-50%, -50%);
    z-index: 0;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn > * {
    position: relative;
    z-index: 1;
}

.btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.btn-primary {
    background-color: var(--primary);
    color: var(--primary-foreground);
    box-shadow: 0 4px 15px rgba(255, 107, 157, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 8px 25px rgba(255, 107, 157, 0.4);
}

.btn-secondary {
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    border: 1px solid var(--border);
}

.btn-icon {
    padding: 10px;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-slow);
    background: var(--secondary);
    color: var(--secondary-foreground);
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.btn-icon span {
    position: relative;
    display: inline-block;
    width: 16px;
    height: 16px;
}

.btn-icon span::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 2px;
    width: 8px;
    height: 2px;
    background: currentColor;
    transform: translateY(-50%);
    border-radius: 1px;
}

.btn-icon span::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 2px;
    right: 2px;
    width: 6px;
    height: 6px;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: translateY(-50%) rotate(-135deg);
    border-radius: 1px;
}

.btn-icon:hover::before {
    width: 60px;
    height: 60px;
}

.btn-icon:hover {
    transform: translateX(-3px) scale(1.1);
    background: var(--primary);
    color: var(--primary-foreground);
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
}

.btn-icon:hover span::before {
    width: 10px;
    left: 1px;
}

.btn-icon:hover span::after {
    left: 1px;
    transform: translateY(-50%) rotate(-135deg) scale(1.1);
}

.btn-icon:active {
    transform: translateX(-1px) scale(1.05);
}

.btn-fab {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    padding: 0;
    justify-content: center;
    align-items: center;
    box-shadow: var(--shadow-lg);
    animation: fabPulse 2s ease-in-out infinite;
}

@keyframes fabPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.btn-export {
    flex-direction: column;
    padding: 20px;
    min-width: 140px;
    text-align: center;
    transition: var(--transition-slow);
}

.btn-export:hover {
    transform: translateY(-5px) scale(1.05);
}

.btn-export .btn-icon {
    font-size: 24px;
    margin-bottom: 8px;
    animation: iconBounce 1s ease-in-out infinite;
}

@keyframes iconBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* List Selector */
.list-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.list-type-btn {
    padding: 24px 20px;
    border: 2px solid var(--border);
    background: var(--card);
    color: var(--card-foreground);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: var(--transition-slow);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.list-type-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 157, 0.1), transparent);
    transition: left 0.6s ease;
}

.list-type-btn:hover::before {
    left: 100%;
}

.list-type-btn:hover {
    border-color: var(--primary);
    transform: translateY(-5px) scale(1.02);
    box-shadow: var(--shadow-lg);
    background: var(--primary);
    color: var(--primary-foreground);
}

.list-type-btn.active {
    background: var(--primary);
    color: var(--primary-foreground);
    border-color: var(--primary);
    transform: scale(1.05);
    box-shadow: var(--shadow-glow);
}

.list-icon {
    font-size: 32px;
    transition: var(--transition);
}

.list-type-btn:hover .list-icon {
    transform: scale(1.2) rotate(5deg);
}

/* Controls */
.controls {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    align-items: center;
}

/* Progress Section */
.progress-section {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.progress-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-pink), var(--accent-purple));
    animation: progressGlow 2s ease-in-out infinite alternate;
}

@keyframes progressGlow {
    0% { opacity: 0.5; }
    100% { opacity: 1; }
}

.progress-section:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.progress-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
}

.progress-bar {
    background: var(--secondary);
    border-radius: var(--radius-md);
    height: 10px;
    margin-bottom: 15px;
    overflow: hidden;
    position: relative;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: progressShine 2s ease-in-out infinite;
}

@keyframes progressShine {
    0% { left: -100%; }
    100% { left: 100%; }
}

.progress-fill {
    background: linear-gradient(90deg, var(--accent-pink), var(--accent-purple));
    height: 100%;
    transition: width 0.8s var(--bounce);
    border-radius: var(--radius-md);
    position: relative;
    overflow: hidden;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: fillShine 1.5s ease-in-out infinite;
}

@keyframes fillShine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.progress-stats {
    display: flex;
    gap: 20px;
}

/* Stats */
.stats {
    display: flex;
    gap: 20px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
    padding: 16px;
    background: var(--card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    min-width: 100px;
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.stat::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.stat:hover::before {
    transform: scaleX(1);
}

.stat:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--foreground);
    transition: var(--transition);
}

.stat:hover .stat-number {
    transform: scale(1.1);
    color: var(--primary);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--muted-foreground);
    margin-top: 5px;
}

/* Category Styles */
.category {
    margin-bottom: 40px;
    background: var(--card);
    border-radius: var(--radius-xl);
    padding: 24px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.category::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(255, 107, 157, 0.05) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.category:hover::before {
    opacity: 1;
}

.category:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(255, 107, 157, 0.3);
}

.category-header {
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.category-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--foreground);
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.category:hover .category-title {
    color: var(--primary);
}

.category-title::before {
    content: "";
    display: block;
    width: 12px;
    height: 12px;
    border-radius: 4px;
    background: linear-gradient(135deg, var(--accent-pink), var(--accent-purple));
    transition: var(--transition);
    animation: titleDot 2s ease-in-out infinite;
}

@keyframes titleDot {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.category:hover .category-title::before {
    transform: scale(1.3);
    box-shadow: 0 0 10px rgba(255, 107, 157, 0.5);
}

.category-description {
    color: var(--muted-foreground);
    font-size: 0.95rem;
    margin-bottom: 15px;
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

.subcategory {
    margin-bottom: 20px;
}

.subcategory-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--muted-foreground);
    padding-left: 10px;
    border-left: 3px solid var(--primary);
    transition: var(--transition);
    position: relative;
    z-index: 1;
}

.category:hover .subcategory-title {
    border-left-color: var(--accent-teal);
    padding-left: 15px;
}

.items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    position: relative;
    z-index: 1;
}

.kink-item {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.kink-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 157, 0.05), transparent);
    transition: left 0.5s ease;
}

.kink-item:hover::before {
    left: 100%;
}

.kink-item:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}

.item-name {
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--foreground);
    font-size: 1rem;
    position: relative;
    z-index: 1;
    transition: var(--transition);
}

.kink-item:hover .item-name {
    color: var(--primary);
}

.item-description {
    font-size: 0.9rem;
    color: var(--muted-foreground);
    margin-bottom: 15px;
    line-height: 1.4;
    position: relative;
    z-index: 1;
}

.preference-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.subcategory-preferences {
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.subcategory-choice {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.subcategory-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--muted-foreground);
    padding: 4px 8px;
    background: var(--secondary);
    border-radius: var(--radius-sm);
    text-align: center;
    transition: var(--transition);
}

.subcategory-choice:hover .subcategory-label {
    background: var(--primary);
    color: var(--primary-foreground);
    transform: scale(1.02);
}

.pref-btn {
    padding: 8px 12px;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: var(--transition-slow);
    opacity: 0.8;
    min-width: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.pref-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transition: width 0.3s ease, height 0.3s ease;
    transform: translate(-50%, -50%);
}

.pref-btn:hover::before {
    width: 100px;
    height: 100px;
}

.pref-btn:hover {
    opacity: 1;
    transform: scale(1.1) rotate(2deg);
}

.pref-btn.active {
    opacity: 1;
    transform: scale(1.15);
    box-shadow: var(--shadow-sm);
    animation: activeButton 0.3s var(--bounce);
}

@keyframes activeButton {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1.15); }
}

.pref-favorite { background-color: var(--color-favorite); color: white; }
.pref-like { background-color: var(--color-like); color: white; }
.pref-indifferent { background-color: var(--color-indifferent); color: white; }
.pref-maybe { background-color: var(--color-maybe); color: white; }
.pref-dislike { background-color: var(--color-dislike); color: white; }
.pref-not-entered { background-color: var(--color-not-entered); color: var(--foreground); }

/* Preference Legend */
.preference-legend {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin: 30px 0;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.preference-legend::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-pink), var(--accent-purple));
    animation: legendGlow 3s ease-in-out infinite alternate;
}

@keyframes legendGlow {
    0% { opacity: 0.5; }
    100% { opacity: 1; }
}

.preference-legend:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.preference-legend h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
    z-index: 1;
}

.preference-legend h3::before {
    content: "❓";
    font-size: 1.2rem;
    animation: questionMark 2s ease-in-out infinite;
}

@keyframes questionMark {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-5deg); }
    75% { transform: rotate(5deg); }
}

.legend-items {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    padding: 5px 10px;
    border-radius: var(--radius-md);
}

.legend-item:hover {
    background: var(--secondary);
    transform: scale(1.05);
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: var(--radius-sm);
    display: inline-block;
    transition: var(--transition);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.legend-item:hover .legend-color {
    transform: scale(1.2);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.legend-label {
    font-size: 0.9rem;
    color: var(--foreground);
    font-weight: 500;
}

/* Completion Page */
.completion-page {
    text-align: center;
    padding: 40px 20px;
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.completion-header {
    margin-bottom: 40px;
}

.completion-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: celebrationBounce 1s ease-in-out infinite;
}

@keyframes celebrationBounce {
    0%, 100% { transform: scale(1) rotate(0deg); }
    25% { transform: scale(1.1) rotate(-5deg); }
    75% { transform: scale(1.1) rotate(5deg); }
}

.completion-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--foreground);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    animation: titleGlow 2s ease-in-out infinite alternate;
}

@keyframes titleGlow {
    0% { text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); }
    100% { text-shadow: 0 2px 4px rgba(255, 107, 157, 0.3); }
}

.completion-page p {
    font-size: 1.1rem;
    color: var(--muted-foreground);
    max-width: 600px;
    margin: 0 auto;
}

.export-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin: 20px 0;
    flex-wrap: wrap;
}

/* Floating Actions */
.floating-actions {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
    z-index: 1000;
    animation: floatingFloat 3s ease-in-out infinite;
}

@keyframes floatingFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: var(--transition-slow);
    z-index: 1000;
    box-shadow: var(--shadow-md);
    animation: themeToggleFloat 4s ease-in-out infinite;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

@keyframes themeToggleFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-3px) rotate(5deg); }
}

.theme-toggle:hover {
    transform: scale(1.15) rotate(15deg) translateY(-2px);
    box-shadow: var(--shadow-lg);
    background: var(--primary);
    color: var(--primary-foreground);
    border-color: var(--primary);
}

.theme-toggle:active {
    transform: scale(1.05) rotate(5deg);
    transition: transform 0.1s ease;
}

/* Utility Classes */
.hidden {
    display: none;
}

/* Scroll animations */
@keyframes slideInFromLeft {
    0% {
        opacity: 0;
        transform: translateX(-50px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInFromRight {
    0% {
        opacity: 0;
        transform: translateX(50px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Apply animations to elements as they come into view */
.category:nth-child(odd) {
    animation: slideInFromLeft 0.6s ease-out;
}

.category:nth-child(even) {
    animation: slideInFromRight 0.6s ease-out;
}

.kink-item {
    animation: fadeIn 0.4s ease-out;
    animation-fill-mode: both;
}

.kink-item:nth-child(1) { animation-delay: 0.1s; }
.kink-item:nth-child(2) { animation-delay: 0.2s; }
.kink-item:nth-child(3) { animation-delay: 0.3s; }
.kink-item:nth-child(4) { animation-delay: 0.4s; }
.kink-item:nth-child(5) { animation-delay: 0.5s; }
.kink-item:nth-child(6) { animation-delay: 0.6s; }

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .header {
        flex-direction: column;
        text-align: center;
        min-height: 250px;
        gap: 20px;
    }
    
    .header-content,
    .header-graphic {
        padding: 20px;
    }
    
    .header-content h1 {
        font-size: 2rem;
    }
    
    .header-graphic {
        justify-content: center;
    }
    
    .sticky-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .items-grid {
        grid-template-columns: 1fr;
    }
    
    .list-selector {
        grid-template-columns: 1fr;
    }
    
    .progress-stats {
        flex-direction: column;
        gap: 15px;
    }
    
    .legend-items {
        flex-direction: column;
        gap: 12px;
    }
    
    .export-buttons {
        flex-direction: column;
    }
    
    .floating-actions {
        bottom: 20px;
        right: 20px;
    }
    
    .floating-actions .btn {
        font-size: 12px;
        padding: 10px 15px;
    }
    
    /* Reduce animations on mobile for better performance */
    .category:nth-child(odd),
    .category:nth-child(even) {
        animation: fadeIn 0.4s ease-out;
    }
    
    .kink-item {
        animation-delay: 0s !important;
    }
}

@media (max-width: 480px) {
    .header {
        min-height: 200px;
    }
    
    .header-content,
    .header-graphic {
        padding: 15px;
    }
    
    .header-content h1 {
        font-size: 1.8rem;
    }
    
    .btn {
        padding: 10px 15px;
        font-size: 13px;
    }
    
    .category {
        padding: 20px 15px;
    }
    
    .kink-item {
        padding: 15px;
    }
    
    .preference-buttons {
        justify-content: center;
    }
    
    /* Completion page specific styles */
    .completion-page {
        text-align: center;
        padding: 40px 20px;
    }

    .completion-header {
        margin-bottom: 40px;
    }

    .completion-icon {
        font-size: 4rem;
        margin-bottom: 20px;
    }

    .completion-title {
        font-size: 2.5rem;
        font-weight: 700;
        margin-bottom: 15px;
        color: var(--foreground);
    }

    .completion-page p {
        font-size: 1.1rem;
        color: var(--muted-foreground);
        max-width: 600px;
        margin: 0 auto;
    }

    .export-buttons {
        display: flex;
        gap: 20px;
        justify-content: center;
        margin: 20px 0;
        flex-wrap: wrap;
    }

    .stats-container {
        margin: 30px 0;
    }

    .stats {
        display: flex;
        gap: 20px;
        justify-content: center;
        flex-wrap: wrap;
    }

    .stat {
        text-align: center;
        padding: 16px;
        background: var(--card);
        border-radius: var(--radius-lg);
        border: 1px solid var(--border);
        min-width: 100px;
    }

    .stat-number {
        font-size: 1.8rem;
        font-weight: 700;
        color: var(--foreground);
    }

    .stat-label {
        font-size: 0.85rem;
        color: var(--muted-foreground);
        margin-top: 5px;
    }

    .controls {
        display: flex;
        gap: 15px;
        justify-content: center;
        margin-top: 30px;
        flex-wrap: wrap;
    }
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
