/* Custom Font Declarations */
@font-face {
    font-family: 'RokuUI';
    src: url('assets/fonts/RokuUI-Regular.vfc') format('vfc');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'RokuUI';
    src: url('assets/fonts/RokuUI-Medium.vfc') format('vfc');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'RokuUI';
    src: url('assets/fonts/RokuUI-Bold.vfc') format('vfc');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'RokuUI', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: url('assets/trc-background.png') center center/cover no-repeat, linear-gradient(135deg, #4A1A5C 0%, #2D0B3D 100%);
    color: #FFFFFF;
    overflow-x: hidden;
}

.app-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header Styles */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 36px;
    font-weight: 700;
}

.logo-image {
    height: 28px;
    width: 239px;
    object-fit: contain;
}

.roku-text {
    color: #FFFFFF;
    font-weight: 400;
}

.channel-text {
    color: #FFFFFF;
    font-weight: 400;
}

.header-info {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 18px;
    font-weight: 500;
}

.page-indicator {
    color: #FFFFFF;
    font-weight: 600;
}

.divider {
    color: rgba(255, 255, 255, 0.6);
    font-weight: 400;
    user-select: none;
}

.options {
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: 8px;
}

.options-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.time {
    color: #FFFFFF;
}

.options {
    color: #efefef;
}

.time {
    color: #FFFFFF;
    font-weight: 500;
}

/* Main Content Layout */
.main-content {
    display: flex;
    flex: 1;
    height: calc(100vh - 80px);
}

/* Sidebar Navigation */
.sidebar {
    width: 320px;
    padding: 20px 0;
    overflow-y: auto;
    transition: width 0.3s ease;
}

.sidebar.collapsed {
    width: 100px;
}

.nav-menu {
    list-style: none;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 16px 40px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}

.sidebar.collapsed .nav-item {
    padding: 16px 20px;
    justify-content: center;
}

.sidebar.collapsed .nav-item span {
    display: none;
}

.sidebar.collapsed .nav-icon {
    margin-right: 0;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #FFFFFF;
}

.nav-item.active {
    border-left-color: #FFFFFF;
    border: 2px solid #FFFFFF;
    border-radius: 8px;
    margin: 0;
    padding: 16px 40px;
}

.sidebar.collapsed .nav-item.active {
    margin: 0;
    padding: 16px 20px;
}

.nav-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
    font-size: 18px;
}

.nav-icon-img {
    width: 36px;
    height: 36px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

/* Show normal icons by default, hide active icons */
.nav-icon-normal {
    display: block;
}

.nav-icon-active {
    display: none;
}

/* For focused nav items, show active icons and hide normal icons (highest priority) */
.nav-item.focused .nav-icon-normal {
    display: none;
}

.nav-item.focused .nav-icon-active {
    display: block;
}

/* For current page nav items, show active icons and hide normal icons */
.nav-item.current-page .nav-icon-normal {
    display: none;
}

.nav-item.current-page .nav-icon-active {
    display: block;
}

/* Hover effect - show active icons on hover for non-focused, non-current-page items */
.nav-item:not(.focused):not(.current-page):hover .nav-icon-normal {
    display: none;
}

.nav-item:not(.focused):not(.current-page):hover .nav-icon-active {
    display: block;
}

.nav-item span {
    font-size: 18px;
    font-weight: 500;
    color: #FFFFFF;
    transition: font-weight 0.2s ease;
}

/* Bold text for focused nav items only */
.nav-item.focused span {
    font-weight: 700;
}

/* Bold text for current page nav items */
.nav-item.current-page span {
    font-weight: 500;
}

/* Content Area */
.content-area {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
    scroll-behavior: smooth;
    scroll-snap-type: y proximity;
}

.content-row {
    margin-bottom: 60px;
    transition: margin-top 0.3s ease;
    scroll-snap-align: start;
    scroll-margin-top: 60px;
}

/* Reduce margin when a content title is showing */
.content-row:has(+ .content-focus-title) {
    margin-bottom: 8px;
}

/* Fallback for browsers that don't support :has() */
.content-row.has-focus-title {
    margin-bottom: 8px;
}

.content-row.pushed-down {
    margin-top: 80px;
}

.content-info-panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 15px 20px;
    opacity: 0;
    transform: translateY(-100%);
    transition: all 0.3s ease;
    z-index: 20;
    border-radius: 0 0 8px 8px;
    backdrop-filter: blur(10px);
}

.content-info-panel.visible {
    opacity: 1;
    transform: translateY(0);
}

.content-info-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 5px;
    line-height: 1.2;
}

.content-info-meta {
    font-size: 14px;
    color: #B8B8B8;
    line-height: 1.2;
}

.row-title {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 20px;
    color: #efefef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.row-counter {
    color: #B8B8B8;
    font-weight: 400;
    font-size: 18px;
}

.content-grid {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 0 40px 10px 40px;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
    position: relative;
}

.content-grid::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

/* Enhanced infinite carousel support */
.content-item {
    aspect-ratio: 16/9;
    background: linear-gradient(45deg, #8B5A9B, #A066B0, #B573C4);
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    flex: 0 0 280px;
    min-width: 280px;
    scroll-snap-align: start;
}

/* Add vertical divider between ALL tiles (including last-to-first in infinite scroll) */
.content-item::after {
    content: '';
    position: absolute;
    top: 15%;
    right: -10px;
    height: 70%;
    width: 1px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 5;
    transition: opacity 0.3s ease;
}

/* Hide divider on hover and focus for cleaner look */
.content-item:hover::after,
.content-item.focused::after {
    opacity: 0;
}

/* Cloned items should be visually identical to originals */
.content-item.cloned {
    opacity: 1;
    transition: all 0.3s ease;
}

/* Smooth transition effects for infinite scrolling */
.content-grid[data-original-count] {
    scroll-behavior: smooth;
    transition: scroll-behavior 0.1s ease;
}

/* Visual feedback for infinite carousel navigation */
.content-item.infinite-focus {
    transform: scale(1.02);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.poster-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.content-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    padding: 20px 15px 15px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.content-overlay h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.content-item:hover .poster-image {
    transition: transform 0.3s ease;
}

.content-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Progress Bar Styles for Continue Watching */
.continue-watching-row .progress-bar-container {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 9px;
    background: #121212;
    border-radius: 0;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.continue-watching-row .progress-bar {
    height: 9px;
    background: #7540C4;
    border-radius: 0;
    width: 0%;
    transition: width 0.8s ease-out;
    position: relative;
}

.continue-watching-row .progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 30%;
    height: 100%;
    background: #7540C4;
}

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

/* Enhanced content overlay for Continue Watching */
.continue-watching-row .content-overlay {
    padding: 15px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
}

.continue-watching-row .content-overlay p {
    margin: 0;
    font-size: 12px;
    color: #B8B8B8;
    margin-top: 4px;
}

/* Adjust progress bar position when content is focused */
.continue-watching-row .content-item.focused .progress-bar-container {
    bottom: 0;
    left: 0;
    right: 0;
}

/* Hide text overlays in continue watching tiles */
.continue-watching-row .tile-component .tile-title,
.continue-watching-row .tile-component .tile-subtitle {
    display: none !important;
}

.continue-watching-row .tile-component .tile-overlay {
    display: none !important;
}

/* Hide text in any div that contains title/subtitle in continue watching */
.continue-watching-row .tile-component div:has(.tile-title),
.continue-watching-row .tile-component div:has(.tile-subtitle) {
    display: none !important;
}

/* Alternative approach - hide the div that wraps title/subtitle */
.continue-watching-row .tile-component > div:last-child {
    display: none !important;
}

/* Override any hover/focus states that might show text */
.continue-watching-row .tile-component:hover .tile-title,
.continue-watching-row .tile-component:hover .tile-subtitle,
.continue-watching-row .tile-component.focused .tile-title,
.continue-watching-row .tile-component.focused .tile-subtitle {
    display: none !important;
}

/* Live Badge Styles */
.live-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    display: inline-flex;
    height: 36px;
    padding: 0 12px;
    justify-content: center;
    align-items: center;
    border-radius: 6px;
    background: #BC2145;
    color: #FFFFFF;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(188, 33, 69, 0.4);
    transition: all 0.3s ease;
}

.live-badge:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(188, 33, 69, 0.6);
}

/* Premium Badge Styles */
.premium-badge {
    position: absolute;
    bottom: 12px;
    left: 12px;
    display: inline-flex;
    height: 36px;
    padding: 0 8px;
    justify-content: center;
    align-items: center;
    border-radius: 6px;
    background: rgba(11, 0, 27, 0.8);
    color: #2EC890;
    font-size: 16px;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(11, 0, 27, 0.4);
    transition: all 0.3s ease;
}

.premium-badge:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(11, 0, 27, 0.6);
}

/* Content Focus Title Styles */
.content-focus-title {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 2px 0 0 0;
    margin-bottom: 36px;
    opacity: 0;
    transform: translateY(-8px);
    transition: all 0.3s ease;
}

.content-focus-title.visible {
    opacity: 1;
    transform: translateY(0);
}

.title-text {
    font-size: 28px;
    font-weight: 700;
    color: #efefef;
    margin-bottom: 8px;
    text-align: left;
}

.details-text {
    font-size: 28px;
    font-weight: 400;
    color: #efefef;
    text-align: left;
}

/* Tile Component System */
.tile-component {
    background: linear-gradient(45deg, #8B5A9B, #A066B0, #B573C4);
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    scroll-snap-align: start;
    flex-shrink: 0;
}

/* Promo Banner Tiles */
.tile-promo-small {
    width: 343px;  /* 1716px / 5 for responsive scaling */
    height: 51px;  /* 256px / 5 for responsive scaling */
    aspect-ratio: 1716/256;
}

.tile-promo-large {
    width: 319px;  /* 1596px / 5 for responsive scaling */
    height: 116px; /* 582px / 5 for responsive scaling */
    aspect-ratio: 1596/582;
}

/* 21:9 Banner Tiles */
.tile-21-9-small {
    width: 206px;  /* 411px / 2 for responsive scaling */
    height: 88px;  /* 176px / 2 for responsive scaling */
    aspect-ratio: 21/9;
}

.tile-21-9-medium {
    width: 278px;  /* 556px / 2 for responsive scaling */
    height: 119px; /* 238px / 2 for responsive scaling */
    aspect-ratio: 21/9;
}

.tile-21-9-large {
    width: 423px;  /* 846px / 2 for responsive scaling */
    height: 182px; /* 363px / 2 for responsive scaling */
    aspect-ratio: 21/9;
}

/* 16:9 Tiles (Standard Video) */
.tile-16-9-small {
    width: 206px;  /* 411px / 2 for responsive scaling */
    height: 116px; /* 231px / 2 for responsive scaling */
    aspect-ratio: 16/9;
}

.tile-16-9-medium {
    width: 156px;  /* 556px / 2 for responsive scaling */
    height: 278px; /* 312px / 2 for responsive scaling */
    aspect-ratio: 16/9;
}

.tile-16-9-large {
    width: 423px;  /* 846px / 2 for responsive scaling */
    height: 237px; /* 474px / 2 for responsive scaling */
    aspect-ratio: 9/16;
}

/* 4:3 Tiles (Classic TV) */
.tile-4-3-small {
    width: 162px;  /* 324px / 2 for responsive scaling */
    height: 122px; /* 243px / 2 for responsive scaling */
    aspect-ratio: 4/3;
}

/* 2:3 Tiles (Portrait/Poster) */
.tile-2-3-small {
    width: 133px;  /* 266px / 2 for responsive scaling */
    height: 200px; /* 399px / 2 for responsive scaling */
    aspect-ratio: 2/3;
}

.tile-2-3-medium {
    width: 162px;  /* 324px / 2 for responsive scaling */
    height: 243px; /* 486px / 2 for responsive scaling */
    aspect-ratio: 2/3;
}

.tile-2-3-large {
    width: 206px;  /* 411px / 2 for responsive scaling */
    height: 309px; /* 617px / 2 for responsive scaling */
    aspect-ratio: 2/3;
}

/* Tile Content Styles */
.tile-component .tile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.tile-component .tile-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    padding: 15px 10px 10px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.tile-component .tile-title {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
}

.tile-component .tile-subtitle {
    margin: 4px 0 0 0;
    font-size: 12px;
    color: #B8B8B8;
    line-height: 1.1;
}

/* Tile Focus and Hover States */
.tile-component:hover .tile-image {
    transform: scale(1.05);
}

.tile-component:hover .tile-overlay {
    transform: translateY(0);
}

.tile-component.focused {
    border: 4px solid #FFFFFF !important;
    border-radius: 8px !important;
    transition: all 0.2s ease !important;
    z-index: 15 !important;
    position: relative !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.tile-component.focused .tile-overlay {
    transform: translateY(0) !important;
}

/* Tile Dividers */
.tile-component::after {
    content: '';
    position: absolute;
    top: 15%;
    right: -10px;
    height: 70%;
    width: 1px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 5;
    transition: opacity 0.3s ease;
}

.tile-component:hover::after,
.tile-component.focused::after {
    opacity: 0;
}

/* Progress Bar for Continue Watching Tiles */
.tile-component.continue-watching .progress-bar-container {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 9px;
    background: #121212;
    border-radius: 0;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.tile-component.continue-watching .progress-bar {
    height: 9px;
    background: #7540C4;
    border-radius: 0;
    width: 0%;
    transition: width 0.8s ease-out;
    position: relative;
}

.tile-component.continue-watching .progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 30%;
    height: 100%;
    background: #7540C4;
}

.tile-component.continue-watching.focused .progress-bar-container {
    bottom: 0;
    left: 0;
    right: 0;
}

/* Continue Watching specific styles for large tiles */
.continue-watching-row .tile-component.tile-16-9-large {
    min-width: 423px; /* Ensure consistent sizing */
}

.continue-watching-row .tile-component.tile-16-9-large .tile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Enhanced progress bar styling for large tiles */
.continue-watching-row .tile-component.continue-watching .progress-bar-container {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 9px;
    background: #121212;
    border-radius: 0;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.continue-watching-row .tile-component.continue-watching.focused .progress-bar-container {
    bottom: 0;
    left: 0;
    right: 0;
    height: 9px;
}

/* Responsive Scaling for Tiles */
@media (max-width: 1200px) {
    .tile-promo-small { width: 275px; height: 41px; }
    .tile-promo-large { width: 255px; height: 93px; }
    .tile-21-9-small { width: 165px; height: 71px; }
    .tile-21-9-medium { width: 222px; height: 95px; }
    .tile-21-9-large { width: 338px; height: 145px; }
    .tile-16-9-small { width: 165px; height: 93px; }
    .tile-16-9-medium { width: 222px; height: 125px; }
    .tile-16-9-large { width: 338px; height: 190px; }
    .tile-4-3-small { width: 130px; height: 97px; }
    .tile-2-3-small { width: 106px; height: 160px; }
    .tile-2-3-medium { width: 130px; height: 194px; }
    .tile-2-3-large { width: 165px; height: 247px; }
}

@media (max-width: 768px) {
    .tile-promo-small { width: 206px; height: 31px; }
    .tile-promo-large { width: 191px; height: 70px; }
    .tile-21-9-small { width: 124px; height: 53px; }
    .tile-21-9-medium { width: 167px; height: 71px; }
    .tile-21-9-large { width: 254px; height: 109px; }
    .tile-16-9-small { width: 124px; height: 70px; }
    .tile-16-9-medium { width: 167px; height: 94px; }
    .tile-16-9-large { width: 254px; height: 142px; }
    .tile-4-3-small { width: 97px; height: 73px; }
    .tile-2-3-small { width: 80px; height: 120px; }
    .tile-2-3-medium { width: 97px; height: 146px; }
    .tile-2-3-large { width: 124px; height: 185px; }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .content-item {
        flex: 0 0 240px;
        min-width: 240px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 280px;
    }
    
    .sidebar.collapsed {
        width: 80px;
    }
    
    .header {
        padding: 15px 20px;
    }
    
    .logo {
        font-size: 28px;
    }
    
    .header-info {
        font-size: 16px;
    }
    
    .content-area {
        padding: 20px;
    }
    
    .nav-item {
        padding: 14px 30px;
    }
    
    .sidebar.collapsed .nav-item {
        padding: 14px 15px;
    }
    
    .nav-item.active {
        margin: 4px 15px;
        padding: 12px 26px;
    }
    
    .sidebar.collapsed .nav-item.active {
        margin: 4px 8px;
        padding: 12px 12px;
    }
}

@media (max-width: 480px) {
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
        max-height: 200px;
    }
    
    .nav-menu {
        display: flex;
        overflow-x: auto;
        padding: 0 10px;
    }
    
    .nav-item {
        min-width: 140px;
        padding: 12px 16px;
        flex-direction: column;
        text-align: center;
    }
    
    .nav-item.active {
        margin: 4px;
    }
    
    .nav-icon {
        margin-right: 0;
        margin-bottom: 4px;
    }
    
    .content-item {
        flex: 0 0 200px;
        min-width: 200px;
    }
}

/* Keyboard Navigation Focus Styles */
.nav-item.focused {
    background: rgba(255, 255, 255, 0.25) !important;
    border: 3px solid #FFFFFF !important;
    border-radius: 12px !important;
    margin: 0 !important;
    padding: 16px 40px !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3) !important;
}

.sidebar.collapsed .nav-item.focused {
    margin: 0 !important;
    padding: 16px 20px !important;
}

.content-item.focused {
    border: 4px solid #FFFFFF !important;
    border-radius: 12px 12px 0 0 !important;
    transition: all 0.2s ease !important;
    z-index: 15 !important;
    position: relative !important;
}

.content-item.focused .poster-image {
    transition: transform 0.3s ease;
}

.content-item.focused .content-info-panel {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Prevent focus outline on interactive elements */
.nav-item:focus,
.content-item:focus {
    outline: none;
}

/* Visual feedback for keyboard interaction */
body {
    user-select: none; /* Prevent text selection during keyboard navigation */
}

/* Search Page Styles */
.search-page {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.search-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px 0;
}

/* Search Input Section */
.search-input-section {
    margin-bottom: 40px;
}

.search-input-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    height: 60px;
    padding: 0 20px;
    font-size: 24px;
    color: #FFFFFF;
    background: rgba(255, 255, 255, 0.1);
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    text-align: left;
    caret-color: #FFFFFF;
}

.search-input:focus {
    outline: none;
    border-color: #FFFFFF;
    background: rgba(255, 255, 255, 0.15);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.search-cursor {
    position: absolute;
    top: 50%;
    left: 20px;
    width: 2px;
    height: 30px;
    background: #FFFFFF;
    transform: translateY(-50%);
    animation: blink 1s infinite;
    display: none;
}

.search-cursor.active {
    display: block;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* On-Screen Keyboard */
.keyboard-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-bottom: 40px;
}

.keyboard-row {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.key-btn {
    width: 60px;
    height: 60px;
    font-size: 20px;
    font-weight: 600;
    color: #FFFFFF;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

.key-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.6);
}

.key-btn:active {
    background: rgba(255, 255, 255, 0.3);
}

.key-btn.focused {
    background: rgba(255, 255, 255, 0.3) !important;
    border-color: #FFFFFF !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
}

/* Special Keys */
.key-space {
    width: 200px;
}

.key-delete,
.key-clear {
    width: 80px;
}

.key-delete svg,
.key-clear svg {
    width: 24px;
    height: 24px;
}

/* Search Results Section */
.search-results-section {
    flex: 1;
    margin-top: 20px;
}

.search-results-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    max-height: 300px;
    overflow-y: auto;
}

.search-result-item {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.search-result-item:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.search-result-item.focused {
    background: rgba(255, 255, 255, 0.3) !important;
    border-color: #FFFFFF !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
}

.search-result-title {
    font-size: 16px;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 5px;
}

.search-result-type {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

/* No results message */
.no-results {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 18px;
    margin-top: 40px;
}

/* Responsive Design for Search Page */
@media (max-width: 768px) {
    .keyboard-row {
        gap: 8px;
    }
    
    .key-btn {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
    
    .key-space {
        width: 150px;
    }
    
    .key-delete,
    .key-clear {
        width: 60px;
    }
    
    .search-input {
        height: 50px;
        font-size: 20px;
    }
}
