/* Combined CSS from all local CSS files */

/* 
   ============================================================  
   CATPPUCCIN MOCHA THEME - COLOR PALETTE
   ============================================================
   All buttons follow Catppuccin Mocha color scheme for
   consistency and visual cohesion. Buttons are circular (border-radius: 50%)
   
   PRIMARY COLORS:
   - Background: #1e1e2e (Base)
   - Surface: #313244 (Surface0)
   - Text: #cdd6f4 (Text)
   - Accent: #cba6f7 (Mauve) - Primary highlight
   - Hover: #cba6f7 with scale(1.1+) transform
   
   SPECIALIZED COLORS:
   - Close/Danger: #f38ba8 (Flamingo/Red)
   - Success: #a6e3a1 (Green)
   - Info: #89b4fa (Blue)
   - Warning: #f9e2af (Yellow)
   
   BUTTON HOVER EFFECTS:
   - Scale: 1.1x
   - Shadow: 0 8px 24px rgba(203, 166, 247, 0.3)
   - Transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4)
   ============================================================
*/

/* From b/style/global.css */
@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@600;700&family=Inter:wght@300;400;500;600;700;800&display=swap');

/* Optional: Keep Good Timing if used for specific branding, otherwise Inter is default */
@font-face {
    font-family: "Good Timing Rg";
    src: url("/_a/font/good-timing-bd.otf") format("opentype");
    font-weight: normal;
    font-style: normal;
}

:root {
    /* Edulearn Default Theme (Midnight Indigo / Mint) */
    --bg-dark: #09090b;
    --sidebar-bg: rgba(9, 9, 11, 0.95);
    --surface: #121214;
    --surface-hover: #27272a;
    --border: #27272a;
    --border-light: #3f3f46;
    --text-main: #ffffff;
    --text-muted: #a1a1aa;
    --accent: #86efac;
    --accent-selected: rgba(134, 239, 172, 0.1);
    --accent-glow: rgba(134, 239, 172, 0.15);
    --input-bg: #09090b;
    --panel: var(--surface);
    --shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
    --transition: 0.3s ease;
}

body.theme-edulearn {
    --bg-dark: #09090b;
    --sidebar-bg: rgba(9, 9, 11, 0.95);
    --surface: #121214;
    --surface-hover: #27272a;
    --border: #27272a;
    --border-light: #3f3f46;
    --text-main: #ffffff;
    --text-muted: #a1a1aa;
    --accent: #86efac;
    --accent-selected: rgba(134, 239, 172, 0.1);
    --accent-glow: rgba(134, 239, 172, 0.15);
    --input-bg: #09090b;
}

body.theme-mocha {
    --bg-dark: #1e1e2e;
    --sidebar-bg: rgba(30, 30, 46, 0.95);
    --surface: #11111b;
    --surface-hover: #313244;
    --border: #313244;
    --border-light: #45475a;
    --text-main: #cdd6f4;
    --text-muted: #a6adc8;
    --accent: #cba6f7;
    --accent-selected: rgba(203, 166, 247, 0.12);
    --accent-glow: rgba(203, 166, 247, 0.15);
    --input-bg: #1e1e2e;
}

body.theme-inverted {
    --bg-dark: #f4f4f5;
    --sidebar-bg: rgba(244, 244, 245, 0.95);
    --surface: #ffffff;
    --surface-hover: #e4e4e7;
    --border: #e4e4e7;
    --border-light: #d4d4d8;
    --text-main: #18181b;
    --text-muted: #52525b;
    --accent: #4f46e5;
    --accent-selected: rgba(79, 70, 229, 0.12);
    --accent-glow: rgba(79, 70, 229, 0.15);
    --input-bg: #f4f4f5;
}

body {
    background-color: var(--bg-dark);
    /* Edulearn Subtle Grid */
    background-image: linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
                      linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
    color: var(--text-main);
    font-family: "Inter", system-ui, sans-serif;
    text-align: center;
    margin: 0;
}

h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
    font-weight: 700;
    letter-spacing: -1px;
}

nav {
    background: var(--surface);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

ul {
    list-style-type: none;
    padding: 0;
    display: flex;
    gap: 10px;
}

li {
    margin: 15px 0;
}

a {
    color: var(--text-main);
    text-decoration: none;
    transition: 0.2s;
}

a:hover {
    color: var(--accent);
}

button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    color: #cdd6f4;
    font-family: "Inter", sans-serif;
    font-size: 13px;
    font-weight: 600;
    padding: 12px 12px;
    border: 2px solid #313244;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    background: #313244;
    cursor: pointer;
    white-space: nowrap;
}

button:hover {
    color: #1e1e2e;
    background-color: #cba6f7;
    border-color: #cba6f7;
    transform: scale(1.1) translateY(-2px);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.3);
}

.flex-horiz {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.flex-vert {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

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

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

.greenCircle {
    height: 15px;
    width: 15px;
    background-color: var(--accent); /* Updated to mint green */
    border-radius: 100%;
    box-shadow: 0 0 10px var(--accent-glow);
}

#logo {
    width: 20%;
    filter: none; /* Removed grayscale/brightness to allow native logo colors if any */
}

.title {
    font-family: "Dancing Script", cursive; /* Updated to brand font */
    font-size: 50px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: lowercase;
    margin: 0;
}

.accent {
    color: var(--accent); /* Updated to mint green */
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    color: var(--text-muted);
    text-align: center;
    padding: 15px 0;
    background: transparent;
    font-size: 13px;
    font-weight: 500;
    pointer-events: none; /* Allow clicking through footer background */
}

footer * {
    pointer-events: auto; /* Re-enable clicks on links/content inside footer */
}

.gridContainer {
    width: calc(100% - 100px);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 20px;
    margin-left: 65px;
}

.gridContainer .item {
    padding: 20px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    transition: 0.2s;
}

.gridContainer .item:hover {
    background: rgba(134, 239, 172, 0.05); /* Slight mint tint on hover */
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

/* From b/style/browser.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

.hover-focus1 {
    transition: .2s ease-in-out;
}

.hover-focus1:hover:not(.selectedTab) {
    background-color: var(--surface-hover) !important;
}

.hover-focus2 {
    transition: .2s ease-in-out;
}

.hover-focus2:hover:not(.selectedTab) {
    background-color: rgba(255, 255, 255, 0.05) !important;
}

.sidebar-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 20vw;
    height: 100vh;
    overflow-y: scroll;
    overflow-x: hidden;
    background-color: var(--bg-dark);
    /* Edulearn Subtle Grid */
    background-image: linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
                      linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
}

.sidebar-container header {
    display: flex;
    width: 20vw;
    height: 99vh;
    margin: 0;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    flex-shrink: 0;
    position: absolute;
    left: 0;
    transition: .2s ease-in-out;
    background: transparent;
}

.sidebar-container header.closed {
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border);
    position: fixed;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.sidebar-container header.closed:not(:hover):not(.hovered) {
    transform: translateX(-100%);
}

.sidebar-container header .page-data {
    width: 100%;
    padding: 1.5rem;
    box-sizing: border-box;
}

.sidebar-container header .page-data #controls {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

/* Force the div containing the buttons to align horizontally */
.sidebar-container header .page-data #controls > div {
    display: flex;
    align-items: center;
    gap: 4px;
}

.sidebar-container header .page-data #controls button {
    background-color: #313244;
    border: 2px solid #45475a;
    outline: none;
    color: #cba6f7;
    font: inherit;
    font-weight: 500;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    width: 40px;
    height: 40px;
}

.sidebar-container header .page-data #controls button:hover {
    background-color: #cba6f7;
    border-color: #cba6f7;
    color: #1e1e2e;
    transform: scale(1.1);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.3);
}

.sidebar-container header .page-data #controls button .tooltip {
    padding: 6px 10px;
    position: absolute;
    top: 35px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    background: var(--surface);
    color: var(--text-main);
    visibility: hidden;
    opacity: 0;
    transition: .2s ease;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    border: 1px solid var(--border-light);
    white-space: nowrap;
    z-index: 200;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.sidebar-container header .page-data #controls button:hover .tooltip {
    visibility: visible;
    opacity: 1;
    top: 45px;
}

.logo-name {
    font-size: 16px;
    color: var(--text-main);
    font-weight: 600;
    letter-spacing: -0.5px;
}

.sidebar-container header .page-data #controls button .icon {
    font-size: 1.1rem;
}

.sidebar-container header .page-data #controls button svg {
    width: 24px;
    height: 24px;
    padding: 0;
    margin: 0;
}

.sidebar-container header .page-data #url-form {
    padding: 0 0 1rem 0;
    border-bottom: 1px solid var(--border);
    width: 100%;
}

.sidebar-container header .page-data #url-form input {
    background-color: var(--input-bg);
    border: 1px solid var(--border-light);
    outline: none;
    color: var(--text-main);
    font-family: inherit;
    padding: 10px 14px;
    box-sizing: border-box;
    border-radius: 8px;
    font-size: 13px;
    width: 100%;
    transition: 0.2s;
}

.sidebar-container header .page-data #url-form input:focus {
    border-color: var(--text-main);
}

.sidebar-container header .page-data #new-tab {
    width: 100%;
    margin-top: 1rem;
    border-radius: 8px;
    background-color: transparent;
    border: 1px dashed var(--border-light);
    outline: none;
    color: var(--text-muted);
    font: inherit;
    font-weight: 500;
    padding: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: 0.2s;
    font-size: 13px;
}

.sidebar-container header .page-data #new-tab:hover {
    background-color: rgba(255, 255, 255, 0.02);
    color: var(--text-main);
    border-color: var(--text-main);
}

@keyframes slide-in-from-top {
    0% { transform: translateY(-10px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

@keyframes slide-out-from-bottom {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(-10px); opacity: 0; }
}

.r-alert {
    position: fixed;
    top: 20px;
    right: 20px;
    width: auto;
    padding: 12px 20px;
    background-color: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
    transition: transform .2s ease;
    z-index: 3000;
    color: var(--text-main);
    backdrop-filter: blur(12px);
    font-family: inherit;
}

.r-alert p {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
}

header #tab-list {
    height: calc(100vh - 180px);
    overflow-y: auto;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    gap: 6px;
    padding: 10px 15px;
    box-sizing: border-box;
}

header #tab-list .tab-item {
    position: relative;
    display: flex;
    gap: 10px;
    width: 100%;
    border-radius: 8px;
    background: var(--surface);
    justify-content: flex-start;
    align-items: center;
    cursor: pointer;
    border: 1px solid var(--border);
    outline: none;
    padding: 10px 12px;
    font-family: inherit;
    color: var(--text-muted);
    font-size: 13px;
    animation: slide-in-from-top .2s ease;
    transition: 0.2s;
    box-sizing: border-box;
}

header #tab-list .tab-item:hover {
    color: var(--text-main);
    background-color: var(--surface-hover);
    border-color: var(--border-light);
}

header #tab-list .tab-item img {
    height: 16px;
    width: 16px;
    border-radius: 2px;
}

header #tab-list .tab-item span {
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: calc(100% - 40px);
    text-align: left;
}

header #tab-list .tab-item .close {
    position: absolute;
    right: 8px;
    background-color: transparent;
    border: none;
    outline: none;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 24px;
    height: 24px;
    transition: .2s ease;
    opacity: 0;
}

header #tab-list .tab-item:hover .close {
    opacity: 1;
}

header #tab-list .tab-item .close:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #f87171;
}

header #tab-list .tab-item .close .close-icon {
    font-size: 14px;
    color: inherit;
}

header #tab-list .tab-item.selectedTab {
    background: var(--accent-selected);
    color: var(--accent);
    border: 1px solid var(--accent);
}

header #tab-list .tab-item.selectedTab .close {
    opacity: 1;
    color: var(--accent);
}

#tab-view {
    width: 80vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    right: 0;
    padding: 0;
    margin: 0;
    background-color: #000;
}

#tab-view.full-width {
    width: 100vw;
}

#tab-view .tab-frame {
    height: 100%;
    width: 100%;
    background-color: #ffffff; /* Typically white for rendering proxy content properly */
    border: none;
    outline: none;
}

#small-screen-overlay {
    display: none;
    position: fixed;
    justify-content: center;
    align-items: center;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-dark);
    color: var(--text-main);
    text-align: center;
    z-index: 4000;
    backdrop-filter: blur(10px);
}

#small-screen-overlay p {
    margin: 0 auto;
    width: 80%;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
}

@media(max-width: 768px) {
    #small-screen-overlay {
        display: flex;
    }
}

#menu-overlay {
    position: fixed;
    top: 60px;
    left: 0;
    width: 20vw;
    min-width: 250px;
    height: calc(100% - 60px);
    background-color: var(--surface);
    transform: translateX(-100%);
    transition: .3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    padding: 20px;
    box-sizing: border-box;
    border-right: 1px solid var(--border);
    box-shadow: 10px 0 30px rgba(0, 0, 0, 0.5);
}

#menu-overlay.active {
    transform: translateX(0);
}

.option {
    color: var(--text-muted);
    margin-bottom: 8px;
    cursor: pointer;
    padding: 10px 14px;
    background: transparent;
    transition: .2s ease;
    border-radius: 8px;
    width: 100%;
    font-size: 13px;
    font-weight: 500;
    border: 1px solid transparent;
    box-sizing: border-box;
    display: flex;
    align-items: center;
}

.option:hover {
    background: var(--surface-hover);
    color: var(--text-main);
    border-color: var(--border-light);
}

/* From s/style.css */
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&display=swap');

*, *::before, *::after { box-sizing: border-box; }

.browser-container {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    /* Adding padding so the iframe "floats" inside the window like a bubble */
    padding-bottom: 16px; 
}

.tabs {
    display: flex;
    padding: 16px 16px 8px; /* Extra padding for bounce effect */
    gap: 12px;
    background: transparent;
    overflow-x: auto;
    z-index: 10;
}

.tabs::-webkit-scrollbar { height: 0; }

.tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    min-width: 140px;
    max-width: 220px;
    height: 42px;
    
    /* Bubble Pill Style */
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-top-color: rgba(255, 255, 255, 0.4);
    border-radius: 9999px; /* Perfect pill */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    transform: translate3d(0,0,0);
}

.tab:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-4px);
}

.tab.active {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    transform: scale(1.05);
    z-index: 2;
}

.tab-favicon {
    width: 20px;
    height: 20px;
    border-radius: 50%; /* Circly icons */
    flex-shrink: 0;
}

.tab-title {
    flex: 1;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tab-close {
    font-size: 14px;
    color: #cba6f7;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #313244;
    border: 2px solid #45475a;
}

.tab-close:hover {
    background: #f38ba8;
    border-color: #f38ba8;
    color: #1e1e2e;
    transform: scale(1.2) rotate(90deg);
    box-shadow: 0 8px 24px rgba(243, 139, 168, 0.3);
}

.new-tab {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: #313244;
    border: 2px solid #45475a;
    color: #cba6f7;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    backdrop-filter: blur(5px);
}

.new-tab:hover {
    background: #cba6f7;
    border-color: #cba6f7;
    color: #1e1e2e;
    transform: scale(1.15) translateY(-2px);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.3);
}

.nav {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    margin: 0 16px 16px; /* Floating look */
    
    /* Bubbly Glass Nav Container */
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-top-color: rgba(255, 255, 255, 0.4);
    border-radius: 9999px; /* Circly */
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
    z-index: 100;
}

.nav button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: #313244;
    border: 2px solid #45475a;
    border-radius: 50%;
    color: #cba6f7;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    font-size: 16px;
}

.nav button:hover {
    background: #cba6f7;
    border-color: #cba6f7;
    color: #1e1e2e;
    transform: scale(1.1);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.3);
}

.address-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

input.bar {
    width: 100%;
    height: 44px;
    padding: 0 42px 0 20px;
    
    /* Dark translucent pill */
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid transparent;
    border-radius: 9999px;
    
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    font-family: 'Nunito', sans-serif;
    outline: none;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

input.bar:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    transform: scale(1.02);
}

input.bar::placeholder { color: rgba(255, 255, 255, 0.6); font-weight: 500; }

#home-btn-nav {
    position: absolute;
    right: 10px;
    width: 40px;
    height: 40px;
    background: #313244;
    border: 2px solid #45475a;
    color: #cba6f7;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

#home-btn-nav:hover {
    background: #cba6f7;
    border-color: #cba6f7;
    color: #1e1e2e;
    transform: scale(1.1) rotate(-10deg);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.3);
}

.loading-bar-container {
    height: 4px; /* Slightly thicker */
    width: calc(100% - 60px); /* Fit inside the pill */
    position: absolute;
    bottom: -6px;
    left: 30px;
    z-index: 101;
    border-radius: 999px;
    overflow: hidden;
}

.loading-bar {
    height: 100%;
    width: 0%;
    background: #a855f7;
    box-shadow: 0 0 10px #c084fc;
    transition: width 0.2s ease, opacity 0.15s;
    border-radius: 999px;
}

.iframe-container {
    flex: 1;
    position: relative;
    background: #fff; /* Keep white for actual web pages to render correctly */
    z-index: 0;
    margin: 0 16px; /* Floating bubble look */
    border-radius: 32px; /* Very round corners for the web view */
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
}

.iframe-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    position: absolute;
}

.message-container {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    
    background: rgba(15, 8, 28, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 50;
}

.message-content {
    background: rgba(255, 255, 255, 0.12);
    padding: 40px;
    border-radius: 40px; /* Circly */
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-top-color: rgba(255, 255, 255, 0.4);
    text-align: center;
    max-width: 320px;
    color: #ffffff;
}

.message-content h1 {
    font-size: 1.4rem;
    font-weight: 800;
    margin: 15px 0;
}

.loader-bubbles {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-bottom: 20px;
}

.loader-bubble {
    width: 18px;
    height: 18px;
    background: #ffffff;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(255,255,255,0.4);
    animation: bounceLoader 0.6s infinite alternate cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

.loader-bubble:nth-child(2) { animation-delay: 0.2s; }
.loader-bubble:nth-child(3) { animation-delay: 0.4s; }

@keyframes bounceLoader {
    from { transform: translateY(0) scale(1); }
    to { transform: translateY(-15px) scale(1.2); }
}

.wisp-settings-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

.wisp-settings-modal.hidden { display: none; }

.settings-card {
    width: 480px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    
    /* Bubbly Glass Modal */
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-top-color: rgba(255, 255, 255, 0.4);
    border-radius: 40px; /* Highly rounded */
    box-shadow: 0 20px 50px rgba(0,0,0,0.4);
    overflow: hidden;
    transform: translate3d(0,0,0);
}

.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    background: transparent;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.settings-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 800;
}

.close-btn {
    background: #313244;
    border: 2px solid #45475a;
    color: #f38ba8;
    font-size: 16px;
    cursor: pointer;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

.close-btn:hover { 
    background: #f38ba8; 
    color: #1e1e2e; 
    transform: scale(1.1) rotate(90deg);
    box-shadow: 0 8px 24px rgba(243, 139, 168, 0.3);
}

.settings-content {
    padding: 24px 32px;
    overflow-y: auto;
}

.section-title {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 12px;
    font-weight: 800;
    padding-left: 8px;
}

.wisp-option {
    padding: 16px 20px;
    margin-bottom: 12px;
    background: rgba(0, 0, 0, 0.2); /* Dark bubble */
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 24px; /* Highly rounded */
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

.wisp-option:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.02) translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.wisp-option.active {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.4); /* Glow */
}

.wisp-option-name {
    font-weight: 800;
    font-size: 15px;
    color: #ffffff;
}

.wisp-option-url {
    font-family: 'SF Mono', 'Consolas', monospace;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 4px;
}

.custom-input-group {
    display: flex;
    gap: 12px;
}

.custom-input-group input {
    flex: 1;
    height: 46px;
    padding: 0 20px;
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid transparent;
    border-radius: 9999px; /* Pill */
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    font-family: 'Nunito', sans-serif;
    outline: none;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

.custom-input-group input:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.02);
}

.custom-input-group button {
    height: 46px;
    padding: 0 24px;
    background: #cba6f7;
    border: 2px solid #cba6f7;
    border-radius: 9999px;
    color: #1e1e2e;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
}

.custom-input-group button:hover {
    background: #b896e8;
    border-color: #b896e8;
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.4);
}

@keyframes fadeIn { 
    from { opacity: 0; transform: scale(0.95); } 
    to { opacity: 1; transform: scale(1); } 
}

.status-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
}
.status-indicator.status-success {
    background: #4ade80;
    box-shadow: 0 0 10px rgba(74, 222, 128, 0.6);
}
.status-indicator.status-error { 
    background: #f87171; 
    box-shadow: 0 0 10px rgba(248, 113, 113, 0.6);
}

/* From g/style.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

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

body {
    font-family: 'Inter', system-ui, sans-serif;
    background: linear-gradient(135deg, #020617 0%, #0d1325 55%, #111827 100%);
    color: #f8fafc;
}

header {
    background: transparent;
    border-bottom: 1px solid rgba(96, 165, 250, 0.18);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    height: 80px;
    padding: 0 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.logo {
    font-family: 'Dancing Script', cursive;
    font-size: 32px;
    font-weight: 700;
    color: #f8fafc;
    text-decoration: none;
    display: flex;
    align-items: center;
    letter-spacing: 1px;
    text-transform: lowercase;
    transition: 0.2s ease;
}

.logo:hover {
    transform: scale(1.05);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.logo i, .logo svg {
    color: #3b82f6;
    filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.15));
}

.search-container {
    display: flex;
    flex: 1;
    max-width: 500px;
    gap: 0.75rem;
}

#searchBar, #sortOptions, #filterOptions {
    padding: 10px 16px;
    border: 1px solid #334155;
    border-radius: 8px;
    background: #0f172a;
    color: #f8fafc;
    font-family: inherit;
    font-size: 14px;
    outline: none;
    transition: 0.2s;
}

#searchBar:focus, #sortOptions:focus, #filterOptions:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

#sortOptions option, #filterOptions option {
    background: #0f172a;
    color: #f8fafc;
}

.control-buttons {
    display: flex;
    gap: 15px;
    align-items: center;
}

.control-buttons button {
    background: #313244;
    border: 2px solid #45475a;
    color: #cba6f7;
    cursor: pointer;
    padding: 10px;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.4);
    font-size: 20px;
}

.control-buttons button:hover {
    background: #cba6f7;
    border-color: #cba6f7;
    color: #1e1e2e;
    transform: scale(1.1);
    box-shadow: 0 8px 24px rgba(203, 166, 247, 0.3);
}

.control-buttons button img, .control-buttons button svg {
    max-width: 18px;
    max-height: 18px;
    object-fit: contain;
}

.control-buttons button:hover {
    color: #f8fafc;
    background: rgba(59, 130, 246, 0.08);
}

main {
    margin: 0 auto;
    padding: 2rem 1rem;
    padding-bottom: 6rem;
    max-width: 1200px;
}

#zoneCount {
    color: #9ca3af;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

#zoneCount::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #3b82f6;
    box-shadow: 0 0 8px #3b82f6;
}

#container, #featuredZones {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1.25rem;
}

.zone-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid #1f2937;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    box-shadow: none;
}

.zone-item:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.08);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.25);
}

.zone-item img {
    width: 100%;
    height: 140px; 
    object-fit: cover;
    background: #000;
    opacity: 0.9;
    transition: 0.3s;
    border-bottom: 1px solid #1f2937;
}

.zone-item:hover img {
    opacity: 1;
    transform: scale(1.05);
}

.zone-item button {
    background: transparent;
    color: #f8fafc;
    border: 0;
    padding: 0.85rem;
    font-weight: 500;
    font-size: 13px;
    text-align: center;
    width: 100%;
    cursor: pointer;
    border-top: 1px solid transparent;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis; 
    transition: 0.2s;
}

.zone-item:hover button {
    color: #3b82f6;
}

.zone-item.text-only {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%);
    border: 2px solid rgba(255, 255, 255, 0.1);
    min-height: 80px;
    justify-content: center;
    align-items: center;
}

.zone-item.text-only button {
    font-size: 16px;
    font-weight: 600;
    color: #f8fafc;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.zone-item.text-only:hover {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    border-color: #3b82f6;
    box-shadow: 0 8px 25px rgba(134, 239, 172, 0.3);
}

#zoneViewer {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: none;
    justify-content: center;
    align-items: center;
}

.sandbox-container {
    display: flex;
    flex-direction: column;
    width: 90vw;
    height: 90vh;
    max-width: 1200px;
    max-height: 800px;
    background: #0f172a;
    border: 1px solid #1f2937;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
}

.zone-header {
    background: rgba(15, 23, 42, 0.92);
    border-bottom: 1px solid #1f2937;
    color: #f8fafc;
    padding: 0 1.5rem;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.zone-title {
    display: flex;
    align-items: baseline;
    gap: 12px;
}

#zoneName {
    font-size: 18px;
    font-weight: 600;
    color: #f8fafc;
}

#zoneAuthor {
    font-size: 13px;
    color: #9ca3af;
}

.zone-controls button {
    background: transparent;
    border: 1px solid #334155;
    color: #f8fafc;
    padding: 8px 18px;
    border-radius: 9999px;
    cursor: pointer;
    transition: 0.2s;
    font-size: 13px;
    font-weight: 500;
}

.zone-controls button:hover {
    background: rgba(59, 130, 246, 0.08);
}

.sandbox-toolbar {
    display: flex;
    gap: 8px;
    padding: 12px;
    background: rgba(15, 23, 42, 0.92);
    border-bottom: 1px solid #1f2937;
}

.sandbox-toolbar button {
    background: transparent;
    border: 1px solid #334155;
    color: #f8fafc;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sandbox-toolbar button:hover {
    background: rgba(59, 130, 246, 0.08);
    border-color: #3b82f6;
}

.sandbox-toolbar button svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

#popupOverlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.popup {
    background: #0f172a;
    border: 1px solid #1f2937;
    border-radius: 16px;
    width: 100%;
    max-width: 850px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    transform: scale(0.98);
    transition: transform 0.2s ease;
}

.popup-header {
    background: #0f172a;
    border-bottom: 1px solid #1f2937;
    padding: 24px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #f8fafc;
    font-size: 20px;
    font-weight: 600;
    letter-spacing: normal;
}

#popupClose {
    background: transparent;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    font-size: 20px;
    transition: 0.2s;
}

#popupClose:hover { 
    color: #f8fafc; 
    transform: scale(1.1);
}

#popupBody { 
    padding: 0 32px 32px 32px;
    padding-top: 32px;
}

#popupBody input[type="text"],
#popupBody input[type="file"],
#popupBody select {
    width: 100%;
    padding: 10px 16px;
    margin-bottom: 12px;
    border: 1px solid #334155;
    background: linear-gradient(135deg, #020617 0%, #0d1325 55%, #111827 100%);
    color: #f8fafc;
    border-radius: 8px;
    outline: none;
    font-family: inherit;
    font-size: 14px;
    transition: 0.2s;
}

#popupBody input:focus, #popupBody select:focus { 
    border-color: #f8fafc; 
}

.settings-button {
    width: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 38px;
    padding: 8px 18px;
    background: #f8fafc;
    color: linear-gradient(135deg, #020617 0%, #0d1325 55%, #111827 100%);
    border: none;
    border-radius: 9999px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
    font-size: 13px;
    white-space: nowrap;
}

.settings-button:hover {
    background: #9ca3af;
}

footer {
    background: transparent;
    padding: 1.5rem;
    text-align: center;
    position: fixed;
    bottom: 0;
    width: 100%;
    pointer-events: none;
}

.footer-links {
    pointer-events: auto;
}

.footer-links a {
    color: #9ca3af;
    text-decoration: none;
    margin: 0 10px;
    font-size: 13px;
    font-weight: 500;
    transition: 0.2s;
}

.footer-links a:hover { color: #f8fafc; }

/* Global Navbar Styles */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 18px;
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 10000;
  backdrop-filter: none;
  box-shadow: var(--shadow);
}

.nav-brand {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.4px;
}

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: rgba(255,255,255,0.05);
  color: var(--text-main);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  border-radius: 10px;
  border: 1px solid transparent;
  transition: background var(--transition), border var(--transition), transform var(--transition);
  font-family: Arial, Helvetica, sans-serif;
}

.nav-item:hover, .nav-item.active {
  background: rgba(111, 168, 255, 0.2);
  border-color: rgba(111, 168, 255, 0.35);
  color: #ffffff;
  transform: translateY(-1px);
}

.nav-icons {
  display: flex;
  gap: 12px;
  align-items: center;
}

.nav-icon {
  color: var(--text-main);
  font-size: 18px;
  cursor: pointer;
  transition: transform var(--transition), color var(--transition);
  position: relative;
}

.nav-icon:hover {
  transform: translateY(-1px);
  color: var(--accent);
}

#bell-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  width: 10px;
  height: 10px;
  background-color: #ff4d4d;
  border-radius: 50%;
  display: none;
  box-shadow: 0 0 10px #ff4d4d;
}
#bell-badge.active { display: block; }

.nav-ring {
  display: flex;
  gap: 8px;
}

.navbar.collapsed {
  display: none;
}

#edulearn-navbar-mini {
  position: fixed;
  top: 10px;
  right: 10px;
  background: var(--panel);
  color: var(--text-main);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10001;
  transition: var(--transition);
}

#edulearn-navbar-mini:hover {
  background: var(--surface-hover);
}

/* Nav Button Styles for consistency */
.nav-btn {
    background-color: #0a0a0a;
    color: #e8e8e8;
    border: 1px solid #2a2a2a;
    padding: 4px 8px;
    font-size: 12px;
    cursor: pointer;
    border-radius: 2px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: normal;
    height: 26px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: geometricPrecision;
}

.nav-btn i {
    font-size: 13px;
}

.nav-btn:hover {
    background-color: #1a1a1a;
}