/* ==========================================================================
   GVDTEC MASTER STYLESHEET
   Location: /home/ubuntu/common/styles.css
   ========================================================================== */
:root { 
    --bg-dark: #03030c; 
    --neon-blue: #00f0ff; 
    --neon-purple: #bd00ff; 
    --cyber-gray: #8a99ad; 
    --panel-glow: 0 0 30px rgba(189, 0, 255, 0.15);
    --text-glow: 0 0 10px rgba(0, 240, 255, 0.6), 0 0 20px rgba(0, 240, 255, 0.4);
}

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

body, html { 
    width: 100%; min-height: 100vh; 
    background-color: var(--bg-dark); 
    font-family: 'Rajdhani', sans-serif; color: #fff; 
}

/* ==========================================
   1. BACKGROUND & SCANLINE EFFECTS
   ========================================== */
#bg-canvas, .nebula, .grid-overlay, .scanlines { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
.nebula { background: radial-gradient(circle at 30% 20%, rgba(0,240,255,0.05) 0%, transparent 40%), radial-gradient(circle at 80% 70%, rgba(189,0,255,0.07) 0%, transparent 50%); z-index: 2; }
.grid-overlay { background-image: linear-gradient(rgba(255,255,255,0.01) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.01) 1px, transparent 1px); background-size: 50px 50px; z-index: 3; opacity: 0.7; }
.scanlines { background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255,0,0,0.03), rgba(0,255,0,0.01), rgba(0,0,255,0.03)); background-size: 100% 4px, 6px 100%; z-index: 4; }

/* ==========================================
   2. LAYOUT WRAPPERS
   ========================================== */
/* Used for Apps (like Backup, Diary) - top aligned */
.main-wrapper { position: relative; z-index: 5; display: flex; flex-direction: column; align-items: center; padding: 15px; width: 100%; min-height: 100vh; }
/* Used for Login / Landing pages - center aligned */
.main-container { position: relative; z-index: 5; display: flex; flex-direction: column; justify-content: center; align-items: center; width: 100%; min-height: 100vh; padding: 20px; }

/* ==========================================
   3. GLASSMORPHISM PANELS
   ========================================== */
.panel { 
    background: rgba(5, 5, 20, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--neon-blue); border-radius: 4px; box-shadow: var(--panel-glow); 
    width: 100%; margin-bottom: 15px; position: relative;
}
/* Panel Sizes */
.panel-sm { max-width: 450px; padding: 50px 40px; text-align: center; } /* Login Pages */
.panel-md { max-width: 800px; padding: 20px; } /* Apps like Backup */
.panel-lg { max-width: 900px; padding: 50px 80px; text-align: center; } /* Landing Pages */

/* ==========================================
   4. TYPOGRAPHY & SHIMMER TITLE
   ========================================== */
.shimmer-title { 
    font-family: 'Orbitron', sans-serif; font-weight: 900; letter-spacing: 3px; text-transform: uppercase; margin-bottom: 5px;
    background: linear-gradient(to right, #ff0055 0%, #ff5500 17%, #ffcc00 33%, #00ff66 50%, #00ffff 67%, #aa00ff 83%, #ff0055 100%);
    background-size: 200% auto; -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 10px rgba(0, 240, 255, 0.4)); animation: textShimmer 4s linear infinite;
}
.title-lg { font-size: 3.5rem; letter-spacing: 4px; }
.title-md { font-size: 2.2rem; }
.title-sm { font-size: 1.6rem; margin: 0; }
@keyframes textShimmer { 0% { background-position: 0% center; } 100% { background-position: -200% center; } }
.subtitle { font-family: 'Orbitron', sans-serif; font-size: 1rem; letter-spacing: 3px; color: var(--cyber-gray); text-transform: uppercase; margin-bottom: 35px; }

/* ==========================================
   5. BUTTONS, INPUTS & FORMS
   ========================================== */
.input-cyber, select { 
    width: 100%; padding: 12px; background: rgba(0,240,255,0.05); border: 1px solid var(--neon-blue); 
    color: #fff; outline: none; border-radius: 4px; font-family: monospace; font-size: 16px; 
}
select option { background: var(--bg-dark); color: var(--neon-blue); font-weight: bold; }

.btn-cyber { 
    padding: 14px 20px; background: rgba(0, 240, 255, 0.1); border: 1px solid var(--neon-blue); 
    color: var(--neon-blue); cursor: pointer; text-transform: uppercase; font-family: 'Orbitron'; 
    font-size: 0.9rem; transition: 0.3s; font-weight: bold; width: 100%; border-radius: 4px; display: inline-block; text-align: center; text-decoration: none;
}
.btn-cyber:active, .btn-cyber:hover { background: var(--neon-blue); color: #000; box-shadow: 0 0 15px rgba(0,240,255,0.6); }
.btn-purple { border-color: var(--neon-purple); color: var(--neon-purple); }

/* Application Specific - Tabs & Matrix */
.tab-container { display: flex; gap: 8px; margin-bottom: 15px; }
.tab { flex: 1; padding: 12px 5px; text-align: center; background: rgba(0,240,255,0.05); border: 1px solid var(--neon-blue); cursor: pointer; font-family: 'Orbitron'; font-size: 0.8rem; font-weight: bold; text-transform: uppercase; transition: 0.3s; user-select: none; border-radius: 4px; }
.tab.active { background: var(--neon-blue); color: #000; box-shadow: 0 0 15px rgba(0,240,255,0.6); }
.tab-content { display: none; }
.tab-content.active { display: block; }
.action-matrix { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 15px; }
.btn-action { padding: 14px 10px; background: rgba(189, 0, 255, 0.1); border: 1px solid var(--neon-purple); color: #fff; cursor: pointer; font-family: 'Orbitron'; font-size: 0.8rem; text-transform: uppercase; transition: 0.3s; border-radius: 4px; font-weight: bold; display: flex; align-items: center; justify-content: center; gap: 5px; }
.btn-action:active, .btn-action:hover { background: var(--neon-purple); box-shadow: 0 0 15px rgba(189,0,255,0.6); }

/* Application Specific - Data Blocks */
.master-bar { background: rgba(0, 240, 255, 0.04); border: 1px solid rgba(0, 240, 255, 0.2); padding: 12px; border-radius: 4px; margin-bottom: 15px; display: flex; flex-direction: column; gap: 8px; }
.terminal-box, textarea.config-editor { width: 100%; height: 40vh; max-height: 320px; background: #000; border: 1px solid var(--cyber-gray); color: #00ff00; font-family: monospace; padding: 10px; overflow-y: auto; white-space: pre-wrap; font-size: 0.85rem; margin-bottom: 10px; border-radius: 4px; }
textarea.config-editor { border-color: var(--neon-purple); color: #fff; resize: vertical; outline: none; max-height: 280px; height: 35vh; }
.file-explorer-list { background: #000; border: 1px solid var(--neon-blue); padding: 5px 10px; height: 250px; overflow-y: auto; margin-bottom: 15px; border-radius: 4px; }
.file-row { display: flex; justify-content: flex-start; align-items: center; padding: 8px 5px; border-bottom: 1px solid rgba(0,240,255,0.1); font-family: monospace; font-size: 0.85rem; gap: 10px; }
.file-row.folder-row, .file-row.back-row { cursor: pointer; font-weight: bold; justify-content: space-between; }
.file-row.folder-row { color: var(--neon-blue); }
.file-row.folder-row:hover { background: rgba(0, 240, 255, 0.15); }
.file-row.back-row { color: var(--neon-purple); background: rgba(189,0,255,0.08); }
.file-row.back-row:hover { background: rgba(189,0,255,0.25); }
.file-name-txt { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #fff; }

/* Application Specific - Mini Icons */
.icon-btn-group { display: flex; gap: 5px; flex-shrink: 0; }
.mini-btn { width: 30px !important; height: 30px !important; min-width: 30px !important; min-height: 30px !important; background: rgba(0, 240, 255, 0.1); border: 1px solid var(--neon-blue); color: var(--neon-blue); border-radius: 4px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; font-size: 0.85rem; font-weight: bold; flex-shrink: 0; padding: 0 !important; margin: 0 !important; transition: 0.2s; }
.mini-btn:hover { background: var(--neon-blue); color: #000; box-shadow: 0 0 10px rgba(0,240,255,0.5); }
.mini-btn.purple { border-color: var(--neon-purple); color: var(--neon-purple); background: rgba(189, 0, 255, 0.1); }
.mini-btn.purple:hover { background: var(--neon-purple); color: #fff; box-shadow: 0 0 10px rgba(189,0,255,0.5); }

/* Utility */
.cmd-line { display: flex; align-items: center; gap: 8px; }
.cmd-prefix { color: var(--neon-blue); font-family: monospace; font-weight: bold; font-size: 0.9rem; }
.key-uploader-box { background: rgba(189, 0, 255, 0.05); border: 1px dashed var(--neon-purple); padding: 15px; margin-bottom: 15px; border-radius: 4px; }

/* ==========================================
   6. UNIVERSAL CYBER FOOTER
   ========================================== */
.cyber-footer { width: 100%; max-width: 750px; margin: 20px auto 10px auto; padding: 10px; text-align: center; font-size: 0.85rem; line-height: 1.6; color: var(--cyber-gray); letter-spacing: 1px; z-index: 5; position: relative;}
.footer-segment { margin-bottom: 12px; }
.footer-segment:last-child { margin-bottom: 0; }
.cyber-footer a { color: var(--neon-blue); text-decoration: none; font-weight: 500; transition: all 0.3s ease; display: inline-block; }
.cyber-footer a:hover { color: #ffffff; text-shadow: var(--text-glow); }
.copyright { font-family: 'Orbitron', sans-serif; font-size: 0.8rem; color: rgba(255, 255, 255, 0.6); }

/* Mobile Adjustments */
@media (max-width: 768px) {
    .panel-lg, .panel-sm { padding: 35px 25px; }
    .title-lg { font-size: 2.2rem; letter-spacing: 2px; }
    .subtitle { font-size: 1rem; letter-spacing: 3px; }
    .cyber-footer { font-size: 0.75rem; }
}

/* ==========================================
   7. UNIFIED SITE WRAPPER & GRIDS
   ========================================== */
.site-wrapper {
    width: calc(100% - 40px); max-width: 1400px; margin: 20px auto;
    border: 1px solid var(--neon-blue);
    box-shadow: 0 0 40px rgba(0, 240, 255, 0.15), inset 0 0 30px rgba(0, 240, 255, 0.05);
    background: rgba(3, 3, 12, 0.6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    border-radius: 6px; position: relative; z-index: 5;
    display: flex; flex-direction: column; min-height: calc(100vh - 40px);
}

.hero-section { padding: 80px 20px 40px 20px; text-align: center; display: flex; flex-direction: column; align-items: center; }
.about-text { max-width: 800px; color: #e2e8f0; font-size: 1.1rem; line-height: 1.6; margin: 10px auto 30px auto; letter-spacing: 0.5px; }
.scroll-indicator { color: var(--neon-blue); font-family: 'Orbitron', sans-serif; text-transform: uppercase; font-size: 0.85rem; letter-spacing: 2px; animation: bounce 2s infinite; margin-top: 10px; }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(10px); } }

.projects-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 25px; width: 100%; max-width: 1200px; margin: 0 auto 60px auto; padding: 0 20px; }
.project-card { display: flex; flex-direction: column; align-items: flex-start; text-align: left; padding: 30px; height: 100%; background: rgba(0, 0, 0, 0.5); transition: transform 0.3s ease, box-shadow 0.3s ease; margin-bottom: 0; }
.project-card:hover { transform: translateY(-5px); box-shadow: 0 0 25px rgba(0, 240, 255, 0.3); border-color: var(--neon-blue); }
.project-card h3 { font-size: 1.4rem; margin-bottom: 10px; }
.project-card p { color: var(--cyber-gray); font-size: 1rem; line-height: 1.5; margin-bottom: 25px; flex-grow: 1; }

.policy-content { flex: 1; overflow-y: auto; text-align: left; padding: 0 40px 40px 40px; font-size: 1rem; line-height: 1.6; color: #e2e8f0; letter-spacing: 0.5px; }
.policy-content h2 { font-family: 'Orbitron', sans-serif; font-size: 1.2rem; color: var(--neon-blue); margin: 20px 0 8px 0; text-transform: uppercase; letter-spacing: 1px; }
.policy-content p { margin-bottom: 12px; color: var(--cyber-gray); }

/* ==========================================
   8. UNIFIED 2-COLUMN FOOTER
   ========================================== */
.corp-footer { width: 100%; background: rgba(0, 0, 0, 0.4); padding: 40px 20px 20px 20px; margin-top: auto; border-top: 1px solid rgba(0, 240, 255, 0.15);}
.corp-footer-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 40px; max-width: 800px; margin: 0 auto 30px auto; text-align: center; }
.footer-col h4 { font-family: 'Orbitron', sans-serif; color: var(--neon-blue); font-size: 1.1rem; margin-bottom: 15px; text-transform: uppercase; letter-spacing: 1px; }
.footer-col p, .footer-col a { color: var(--cyber-gray); font-size: 0.95rem; line-height: 1.8; text-decoration: none; display: block; transition: color 0.3s ease; }
.footer-col a:hover { color: #fff; text-shadow: var(--text-glow); }

.classic-footer { text-align: center; border-top: 1px solid rgba(0, 240, 255, 0.15); padding-top: 25px; font-size: 0.85rem; color: var(--cyber-gray); line-height: 1.6; letter-spacing: 1px; max-width: 750px; margin: 0 auto; }
.classic-footer .footer-segment { margin-bottom: 12px; }
.classic-footer .footer-segment:last-child { margin-bottom: 0; }
.classic-footer a { color: var(--neon-blue); text-decoration: none; font-weight: 500; transition: all 0.3s; }
.classic-footer a:hover { color: #fff; text-shadow: var(--text-glow); }

@media (max-width: 768px) {
    .site-wrapper { width: calc(100% - 20px); margin: 10px auto; min-height: calc(100vh - 20px); }
    .hero-section { padding: 40px 15px 30px 15px; }
    .about-text { font-size: 1rem; margin-bottom: 20px; }
    .corp-footer-grid { grid-template-columns: 1fr; gap: 30px; margin-bottom: 20px;}
    .title-lg { font-size: 2.2rem; }
    .policy-content { padding: 0 20px 20px 20px; }
}

/* AI CHAT WIDGET (MOVED HERE FOR CLEAN HTML) */
#cat-widget-container { position: fixed; bottom: 30px; right: 30px; z-index: 9999; display: flex; flex-direction: column; align-items: flex-end; touch-action: none; }
.cat-bubble { background: rgba(5, 5, 20, 0.85); border: 1px solid var(--neon-blue); color: #fff; padding: 12px 18px; border-radius: 20px 20px 0 20px; font-family: 'Rajdhani', sans-serif; font-weight: bold; font-size: 1rem; margin-bottom: 15px; box-shadow: var(--text-glow); opacity: 0; transform: scale(0.8); transform-origin: bottom right; animation: popBubble 0.5s ease forwards; animation-delay: 1.5s; cursor: pointer; user-select: none; }
.cat-avatar { width: 70px; height: 70px; background: rgba(3, 3, 12, 0.9); border: 2px solid var(--neon-blue); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; overflow: hidden; box-shadow: 0 0 15px rgba(0, 240, 255, 0.4); animation: breathe 3s ease-in-out infinite; }
.boy-logo-blink { width: 100%; height: 100%; object-fit: cover; animation: imageSquishBlink 5s infinite; }
@keyframes imageSquishBlink { 0%, 96%, 100% { transform: scaleY(1); } 98% { transform: scaleY(0.1); } }
@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
@keyframes popBubble { to { opacity: 1; transform: scale(1); } }
#chat-window-ui { display: none; width: 350px; height: 500px; background: rgba(5, 5, 20, 0.95); backdrop-filter: blur(10px); border: 1px solid var(--neon-blue); border-radius: 12px; box-shadow: 0 0 30px rgba(0, 240, 255, 0.2); flex-direction: column; overflow: hidden; margin-bottom: 15px; }
@media(max-width: 400px) { #chat-window-ui { width: 90vw; height: 60vh; } }
.chat-header { background: rgba(0, 240, 255, 0.1); padding: 15px; border-bottom: 1px solid var(--neon-blue); display: flex; justify-content: space-between; align-items: center; font-family: 'Orbitron', sans-serif; font-weight: bold; color: var(--neon-blue); }
.close-btn { cursor: pointer; color: #fff; font-size: 1.2rem; }
.chat-body { flex: 1; padding: 15px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.msg { padding: 10px 14px; border-radius: 12px; font-size: 0.95rem; max-width: 80%; line-height: 1.4; }
.msg.bot { background: rgba(0, 240, 255, 0.15); border: 1px solid var(--neon-blue); align-self: flex-start; border-bottom-left-radius: 2px; }
.msg.user { background: rgba(0, 240, 255, 0.15); border: 1px solid var(--neon-blue); align-self: flex-end; border-bottom-right-radius: 2px; }
.chat-footer { padding: 15px; border-top: 1px solid rgba(255,255,255,0.1); display: flex; gap: 10px; }
.chat-input { flex: 1; background: rgba(0,0,0,0.5); border: 1px solid rgba(255,255,255,0.2); color: #fff; padding: 10px; border-radius: 20px; outline: none; }
.send-btn { background: var(--neon-blue); color: #000; border: none; padding: 0 15px; border-radius: 20px; font-weight: bold; cursor: pointer; }