:root {
    --bg-color-dark: #050505;
    --bg-color-card: rgba(18, 18, 18, 0.6);
    --accent-color: #ffdd00;
    --accent-glow: rgba(255, 221, 0, 0.15);
    --text-muted: #888;
    --border-color: rgba(255, 255, 255, 0.08);
    --font-display: Helvetica, Arial, sans-serif;
    --font-body: Helvetica, Arial, sans-serif;
}

html {
    /* Hide scrollbar for IE, Edge and Firefox */
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

html::-webkit-scrollbar {
    display: none;
}

body {
    background: radial-gradient(circle at center, #151515 0%, var(--bg-color-dark) 100%);
    color: white;
    font-family: var(--font-body);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    overflow-x: hidden;
    /* Hide scrollbar for IE, Edge and Firefox */
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

/* Hide scrollbar for Chrome, Safari and Opera */
body::-webkit-scrollbar {
    display: none;
}

/* Home Button - Sleek & Floating */
.home-button-T {
    position: fixed;
    top: 25px;
    left: 25px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    z-index: 1001;
    transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    will-change: transform;
    transform: translateZ(0);
}

.home-button-T:hover {
    background: var(--accent-color);
    color: black;
    transform: scale(1.1) translateY(-2px);
    border-color: var(--accent-color);
    box-shadow: 0 8px 25px rgba(255, 221, 0, 0.3);
}

@media (max-width: 800px) {
    .home-button-T {
        top: auto;
        bottom: 25px;
        left: auto;
        right: 25px;
    }
    
    .header-nav {
        display: none;
    }

    .home-button-T,
    .popup-button-T,
    .fullscreen-button-T,
    .category-btn {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        background: #141414 !important;
    }
    
    .category-btn.active {
        background: var(--accent-color) !important;
    }
    
    .header-title {
        filter: none !important;
    }
}

.shortcuts-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 24px 40px;
    text-align: center;
    box-sizing: border-box;
}

/* Premium Header Styling */
.header-section {
    margin-bottom: 1.2rem;
}

.header-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 2.2rem;
    letter-spacing: 0.15em;
    margin-bottom: 8px;
    text-transform: uppercase;
    background: linear-gradient(135deg, #ffffff 30%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 8px rgba(255, 255, 255, 0.1));
}

.header-subtitle {
    font-size: 0.8rem;
    color: var(--text-muted);
    letter-spacing: 0.29em;
    text-transform: uppercase;
}

.header-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 18px;
}

.header-nav-link {
    font-family: var(--font-display);
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease, transform 0.2s ease;
}

.header-nav-link:hover {
    color: var(--accent-color);
}

/* Super-category Sections */
.super-category {
    margin-bottom: 1.4rem;
    text-align: left;
}

.super-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    letter-spacing: 0.1em;
    color: #fff;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.6rem;
    margin-bottom: 0.8rem;
    text-transform: uppercase;
}

/* Responsive Grid with large gaps */
.shortcuts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 0.7rem;
}

.category-card {
    display: flex;
    flex-direction: column;
}

/* Dropdown button styling */
.category-btn {
    background: var(--bg-color-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: white;
    padding: 0.6rem 1rem;
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    width: 100%;
    outline: none;
    will-change: transform;
}

.category-btn:hover {
    border-color: var(--accent-color);
    box-shadow: 0 10px 30px rgba(255, 221, 0, 0.1), 0 0 20px var(--accent-glow);
    transform: translateY(-2px);
}

.category-btn.active {
    background: var(--accent-color);
    color: black;
    border-color: var(--accent-color);
    box-shadow: 0 10px 30px rgba(255, 221, 0, 0.2), 0 0 20px var(--accent-glow);
}

.category-btn .btn-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.category-icon {
    font-size: 1.15rem;
    color: var(--accent-color);
    transition: color 0.3s ease;
}

.category-btn.active .category-icon {
    color: black;
}

.arrow-icon {
    font-size: 0.95rem;
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.category-btn.active .arrow-icon {
    transform: rotate(180deg);
}

/* Accordion Vertical Expansion Animation */
.dropdown-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.25s ease, padding 0.25s ease;
    opacity: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 0 10px;
    will-change: max-height, opacity;
}

.dropdown-content.open {
    opacity: 1;
    padding: 8px 6px 0;
}

/* Links inside dropdown */
.shortcut-link {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: #d5d5d5;
    padding: 10px 14px;
    text-decoration: none;
    font-family: var(--font-body);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.2s ease;
}

.shortcut-link i {
    font-size: 0.95rem;
    width: 18px;
    text-align: center;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.shortcut-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--accent-color);
    transform: translateX(4px);
    border-color: rgba(255, 221, 0, 0.25);
}

.shortcut-link:hover i {
    color: var(--accent-color);
}

/* Footer styling */
.page-footer {
    text-align: center;
    margin-top: 2rem;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.2);
    letter-spacing: 0.1em;
}

/* Floating Widget Popup Button - Sleek & Floating */
.popup-button-T {
    position: fixed;
    bottom: 25px;
    left: 25px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    z-index: 1001;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    outline: none;
}

.popup-button-T:hover {
    background: var(--accent-color);
    color: black;
    transform: scale(1.1) translateY(-2px);
    border-color: var(--accent-color);
    box-shadow: 0 8px 25px rgba(255, 221, 0, 0.3);
}

/* Hide navigation and popup buttons in widget/popup view */
body.popup-view .popup-button-T,
body.popup-view .home-button-T {
    display: none;
}

/* Custom CSS for Popup/Widget View (320x420) */
body.popup-view {
    overflow-x: hidden;
}

body.popup-view .shortcuts-container {
    padding: 15px 12px 15px;
}

/* Hide header section */
body.popup-view .header-section {
    display: none;
}

/* Make super-category titles smaller and more compact */
body.popup-view .super-category {
    margin-bottom: 0.8rem;
}

body.popup-view .super-title {
    font-size: 0.6rem;
    padding-bottom: 0.3rem;
    margin-bottom: 0.5rem;
}

/* Layout category cards in a 2-column grid in popup view */
body.popup-view .shortcuts-grid {
    /* grid-template-columns: repeat(2, 1fr); */
    grid-template-columns: repeat(auto-fit, minmax(40px, 1fr));
    gap: 0.5rem;
}

/* If a category card has an open dropdown, make it span full width of the grid */
body.popup-view .category-card:has(.dropdown-content.open) {
    grid-column: 1 / -1;
}

/* Hide text and arrow in category buttons, only keep icon */
body.popup-view .category-btn {
    justify-content: center;
    padding: 0.5rem;
    height: 38px;
    min-width: 0 !important;
}

body.popup-view .category-btn .btn-left {
    font-size: 0;
    gap: 0;
}

body.popup-view .category-btn .category-icon {
    font-size: 1.2rem;
    margin: 0;
}

body.popup-view .category-btn .arrow-icon {
    display: none;
}

/* Custom styling for dropdown links inside popup/widget view */
body.popup-view .dropdown-content .shortcut-link {
    font-size: 0.75rem;
    padding: 6px 10px;
    min-width: 90px;
}

/* Hide icons inside dropdown content links in popup view */
body.popup-view .dropdown-content .shortcut-link i {
    display: none;
}

/* Floating Fullscreen Button - shown only in popup view */
.fullscreen-button-T {
    position: fixed;
    bottom: 25px;
    left: 25px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: none; /* Hidden by default in normal view */
    align-items: center;
    justify-content: center;
    text-decoration: none;
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    z-index: 1001;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    outline: none;
}

.fullscreen-button-T:hover {
    background: var(--accent-color);
    color: black;
    transform: scale(1.1) translateY(-2px);
    border-color: var(--accent-color);
    box-shadow: 0 8px 25px rgba(255, 221, 0, 0.3);
}

body.popup-view .fullscreen-button-T {
    display: flex; /* Shown only in popup view */
}