/* IvyDent App Update Page - Light Mode Theme & Mock Windows Stylesheet */

:root {
    /* Bright theme matching the main landing page */
    --bg-primary: #FAFAFD;
    
    /* Inherit/Establish light glass values */
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-border: rgba(255, 255, 255, 0.85);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.05);
    
    --text-main: #1A1A2E;
    --text-muted: #4A4A68;
    
    --sapphire-blue: var(--primary);
}

body {
    background-color: var(--bg-primary);
    color: var(--text-main);
}

/* Nav Logo text color fix (matching main page) */
.logo span {
    color: var(--text-main) !important;
}

/* Scrolled navigation matching main page */
.glass-nav.scrolled {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.nav-links a {
    color: var(--text-main);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary) !important;
}

/* Glowing Neon Badge */
.badge-new {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--accent-gradient);
    color: white;
    font-weight: 800;
    font-size: 0.7rem;
    border-radius: 50px;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
    box-shadow: 0 5px 15px rgba(247, 37, 133, 0.25);
    text-transform: uppercase;
}

/* Download Card */
.download-card {
    margin-top: 2rem;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.04);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
}

.download-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 1.2rem;
    margin-bottom: 1.5rem;
}

.version-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.version-number {
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.active-status {
    background: rgba(0, 229, 255, 0.08);
    color: var(--primary);
    border: 1px solid rgba(67, 97, 238, 0.2);
}

.release-date {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.download-action {
    margin: 1.8rem 0;
}

.file-details {
    list-style: none;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding-top: 1.2rem;
}

.file-details strong {
    color: var(--text-main);
}

/* Download Progress Bar */
.download-progress-container {
    margin-top: 1.2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.progress-bar-bg {
    flex: 1;
    height: 8px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    width: 0;
    background: var(--primary-gradient);
    border-radius: 4px;
    transition: width 0.1s linear;
    box-shadow: 0 0 10px rgba(67, 97, 238, 0.2);
}

.progress-percent {
    font-weight: 800;
    color: var(--primary);
    font-size: 1rem;
    width: 45px;
    text-align: right;
}

/* Live CSS Mock Windows updater */
.mock-window-frame {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 30px 60px rgba(31, 38, 135, 0.08);
    border-radius: var(--radius-lg);
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 400px;
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
    transition: all 0.3s ease;
}

.mock-titlebar {
    background: rgba(240, 241, 247, 0.9);
    padding: 0.8rem 1.5rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
}

.mock-controls {
    display: flex;
    gap: 6px;
}

.mock-control {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.mock-close { background: #FF5F56; }
.mock-minimize { background: #FFBD2E; }
.mock-maximize { background: #27C93F; }

.mock-title {
    flex: 1;
    text-align: center;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-right: 36px;
}

.mock-body {
    flex: 1;
    padding: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(255,255,255,0.4), rgba(240,241,247,0.4));
}

.mock-app-content {
    width: 100%;
    text-align: center;
}

.mock-logo-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.mock-logo-wrapper h2 {
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0;
    letter-spacing: -1px;
}

.mock-status-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.mock-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(67, 97, 238, 0.1);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.mock-status-text {
    font-weight: 600;
    color: var(--text-main);
}

.mock-update-progress {
    width: 100%;
    max-width: 350px;
    margin: 0 auto;
}

.mock-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.mock-progress-fill {
    width: 0;
    height: 100%;
    background: var(--primary-gradient);
    border-radius: 3px;
    transition: width 0.1s linear;
}

.mock-progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-muted);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Success Panel */
.success-panel {
    background: linear-gradient(135deg, rgba(67, 97, 238, 0.04), rgba(0, 229, 255, 0.04));
    border: 1px solid rgba(67, 97, 238, 0.15);
    padding: 3rem;
}

.success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: bounce 1s infinite alternate;
}

@keyframes bounce {
    0% { transform: translateY(0); }
    100% { transform: translateY(-10px); }
}

/* Auto-Update Endpoint Info Card */
.api-panel {
    background: linear-gradient(135deg, rgba(67, 97, 238, 0.02), rgba(0, 229, 255, 0.02));
    border: 1px solid rgba(67, 97, 238, 0.1);
    padding: 2rem 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.api-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.api-badge {
    background: rgba(0, 229, 255, 0.1);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid rgba(67, 97, 238, 0.15);
}

.api-panel h3 {
    font-size: 1.3rem;
    margin: 0;
}

.api-panel p {
    font-size: 0.95rem;
    margin: 0;
}

.api-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding-top: 1rem;
    margin-top: 0.5rem;
}

.api-endpoint-url {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.api-endpoint-url code {
    background: rgba(0, 0, 0, 0.04);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    color: var(--primary);
    font-family: monospace;
    font-weight: 600;
}

/* Accordion Component */
.accordion-container {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.accordion-item {
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--glass-bg);
}

.accordion-item:hover {
    border-color: rgba(67, 97, 238, 0.15);
    transform: translateY(-2px);
}

.accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.8rem 2.5rem;
    user-select: none;
}

.accordion-title-wrapper {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.version-dot {
    width: 10px;
    height: 10px;
    background: var(--text-muted);
    border-radius: 50%;
    transition: all 0.3s;
}

.accordion-item.active .version-dot {
    background: var(--primary);
    box-shadow: 0 0 10px rgba(67, 97, 238, 0.4);
}

.badge-accordion-new {
    background: var(--accent);
    color: white;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 3px 8px rgba(247, 37, 133, 0.2);
}

.accordion-icon {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-muted);
    transition: transform 0.3s;
}

.accordion-item.active .accordion-icon {
    transform: rotate(180deg);
}

.accordion-content {
    padding: 0 2.5rem 2.5rem 2.5rem;
    display: none;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.accordion-item.active .accordion-content {
    display: block;
    animation: slideDown 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.notes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
    margin-top: 1.8rem;
}

@media (max-width: 768px) {
    .notes-grid {
        grid-template-columns: 1fr;
    }
}

.note-block {
    background: rgba(0, 0, 0, 0.01);
    border: 1px solid rgba(0, 0, 0, 0.03);
    border-radius: var(--radius-md);
    padding: 1.8rem;
    transition: background 0.3s;
}

.note-block:hover {
    background: rgba(0, 0, 0, 0.02);
}

.note-type {
    font-size: 0.7rem;
    font-weight: 800;
    margin-bottom: 0.6rem;
    letter-spacing: 1px;
}

.note-type-feature {
    color: var(--primary);
}

.note-type-improvement {
    color: var(--primary-light);
}

.note-block h4 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
    color: var(--text-main);
}

.note-block p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 0;
}

/* Installation Step Grid */
.guide-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.guide-step-card {
    position: relative;
    padding: 3.5rem 2rem 2rem 2rem;
    background: var(--glass-bg);
}

.step-num-badge {
    position: absolute;
    top: -22px;
    left: 2rem;
    width: 48px;
    height: 48px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: white;
    font-size: 1.2rem;
    box-shadow: 0 5px 15px rgba(67, 97, 238, 0.3);
}

.guide-step-card h3 {
    font-size: 1.3rem;
    color: var(--text-main);
    margin-bottom: 0.8rem;
}

.guide-step-card p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 0;
}

/* Support Avatar Card (Graphic headset SVG layout) */
.support-icon-wrapper {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--primary-gradient);
    margin: 0 auto 1.5rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 10px 25px rgba(67, 97, 238, 0.25);
}

.support-svg {
    width: 36px;
    height: 36px;
}

.contact-panel {
    background: linear-gradient(135deg, rgba(67, 97, 238, 0.03), rgba(114, 9, 183, 0.03));
    border: 1px solid rgba(67, 97, 238, 0.1);
}

/* Interactive Floating Raccoon Mascot (Easter Egg) */
.raccoon-wrapper {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.raccoon-bubble {
    background: rgba(255, 255, 255, 0.98);
    color: #1A1A2E;
    border-radius: 16px;
    padding: 0.8rem 1.2rem;
    font-size: 0.9rem;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    margin-bottom: 12px;
    max-width: 240px;
    position: relative;
    opacity: 0;
    transform: translateY(10px) scale(0.9);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.raccoon-wrapper:hover .raccoon-bubble,
.raccoon-wrapper.talk-active .raccoon-bubble {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.raccoon-bubble-arrow {
    position: absolute;
    bottom: -8px;
    right: 25px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid rgba(255, 255, 255, 0.98);
}

.raccoon-sprite-container {
    animation: floatRaccoon 4s infinite ease-in-out alternate;
}

@keyframes floatRaccoon {
    0% { transform: translateY(0); }
    100% { transform: translateY(-8px); }
}

.raccoon-wrapper:hover .pixel-raccoon {
    transform: scale(1.08) translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15), inset -4px -4px 0 rgba(0,0,0,0.15);
}

/* Beautiful Custom CSS Raccoon Sprite */
.pixel-raccoon {
    position: relative;
    width: 60px;
    height: 55px;
    background: #8E90A3; /* Gray raccoon body */
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1), inset -4px -4px 0 rgba(0,0,0,0.15);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.raccoon-ears {
    position: absolute;
    top: -8px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 4px;
}

.ear-left, .ear-right {
    width: 14px;
    height: 14px;
    background: #4A4B57;
    border: 4px solid #8E90A3;
    border-radius: 4px;
}

.raccoon-face {
    position: absolute;
    bottom: 12px;
    left: 4px;
    right: 4px;
    height: 28px;
    background: #F1F1F6; /* Light mask face */
    border-radius: 8px;
}

.raccoon-mask {
    position: absolute;
    top: 4px;
    left: 2px;
    right: 2px;
    height: 12px;
    background: #2E2F38; /* Dark raccoon mask around eyes */
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
    padding: 0 8px;
}

.eye-left, .eye-right {
    position: relative;
    top: 2px;
    width: 6px;
    height: 8px;
    background: #FFFFFF;
    border-radius: 2px;
}

.pupil {
    position: absolute;
    top: 2px;
    left: 1px;
    width: 4px;
    height: 4px;
    background: #000000;
    border-radius: 50%;
}

.raccoon-snout {
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 14px;
    height: 8px;
    display: flex;
    justify-content: center;
}

.raccoon-nose {
    width: 8px;
    height: 5px;
    background: #111111;
    border-radius: 3px;
}

.raccoon-body {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 12px;
}

.raccoon-arms {
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
}

.arm-left, .arm-right {
    width: 8px;
    height: 10px;
    background: #4A4B57;
    border-radius: 0 0 4px 4px;
}

.raccoon-tail {
    position: absolute;
    right: -16px;
    bottom: 4px;
    width: 22px;
    height: 12px;
    background: repeating-linear-gradient(
        90deg,
        #2E2F38,
        #2E2F38 5px,
        #8E90A3 5px,
        #8E90A3 10px
    );
    border-radius: 4px;
    transform-origin: left center;
    animation: tailWag 3s infinite ease-in-out alternate;
}

@keyframes tailWag {
    0% { transform: rotate(-8deg); }
    100% { transform: rotate(18deg); }
}

/* Responsive grid layout adaptations */
@media (max-width: 992px) {
    main {
        padding-top: 100px;
    }
    .hero-content {
        flex-direction: column;
        gap: 3rem;
    }
    .download-card {
        padding: 1.5rem;
    }
    .file-details {
        flex-direction: column;
        gap: 0.5rem;
    }
    .mock-window-frame {
        height: 350px;
    }
}
