/* CSS Variables for theming - Liquid Glass Design */
:root {
    /* Light Theme (Default) */
    --lg-bg-color: rgba(255, 255, 255, 0.15);
    --lg-highlight: rgba(255, 255, 255, 0.9);
    --lg-text: #ffffff;
    --lg-hover-glow: rgba(255, 255, 255, 0.5);
    --lg-shadow: rgba(0, 0, 0, 0.15);

    --bg-primary: rgba(255, 255, 255, 0.12);
    --bg-secondary: rgba(255, 255, 255, 0.18);
    --bg-tertiary: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.25);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.9);
    --text-tertiary: rgba(255, 255, 255, 0.7);
    --accent-color: #00d4ff;
    --accent-glow: rgba(0, 212, 255, 0.6);
    --blur-amount: 40px;
    --blur-strong: 60px;
    --border-radius: 24px;
    --border-radius-lg: 32px;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    --shadow-hover: 0 12px 48px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 40px var(--accent-glow);
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Dark Theme */
html.theme-dark,
body.theme-dark {
    --lg-bg-color: rgba(15, 15, 25, 0.4);
    --lg-highlight: rgba(255, 255, 255, 0.15);
    --lg-shadow: rgba(0, 0, 0, 0.5);

    --bg-primary: rgba(15, 15, 25, 0.5);
    --bg-secondary: rgba(20, 20, 35, 0.6);
    --bg-tertiary: rgba(10, 10, 20, 0.4);
    --glass-border: rgba(255, 255, 255, 0.15);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.85);
    --text-tertiary: rgba(255, 255, 255, 0.6);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
    --shadow-hover: 0 12px 48px rgba(0, 0, 0, 0.8);
}

/* Light Theme */
html.theme-light,
body.theme-light {
    --lg-bg-color: rgba(255, 255, 255, 0.2);
    --lg-highlight: rgba(255, 255, 255, 1);
    --lg-shadow: rgba(0, 0, 0, 0.1);

    --bg-primary: rgba(255, 255, 255, 0.25);
    --bg-secondary: rgba(255, 255, 255, 0.35);
    --bg-tertiary: rgba(255, 255, 255, 0.15);
    --glass-border: rgba(255, 255, 255, 0.4);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.95);
    --text-tertiary: rgba(255, 255, 255, 0.75);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    --shadow-hover: 0 12px 48px rgba(0, 0, 0, 0.25);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    width: 100vw;
    position: relative;
}

/* ========== LIQUID GLASS BASE SYSTEM ========== */
.glass-container {
    position: relative;
    display: flex;
    align-items: center;
    color: var(--lg-text);
    background: transparent;
    border-radius: 2rem;
    overflow: hidden;
    box-shadow: 0 6px 6px var(--lg-shadow), 0 0 20px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 2.2);
}

.glass-filter {
    position: absolute;
    inset: 0;
    z-index: 0;
    backdrop-filter: blur(30px) saturate(180%) brightness(1.1);
    -webkit-backdrop-filter: blur(30px) saturate(180%) brightness(1.1);
    isolation: isolate;
}

.glass-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: var(--lg-bg-color);
}

.glass-specular {
    position: absolute;
    inset: 0;
    z-index: 2;
    border-radius: inherit;
    overflow: hidden;
    box-shadow:
        inset 0 1px 1px var(--lg-highlight),
        inset 1px 0 1px rgba(255, 255, 255, 0.5),
        inset 0 0 20px rgba(255, 255, 255, 0.1);
    pointer-events: none;
}

.glass-content {
    position: relative;
    z-index: 3;
    display: flex;
    align-items: center;
    width: 100%;
    height: 100%;
}

/* Background */
#background-image {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
    transition: opacity 1s ease-in-out;
}

#background-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.4) 100%);
    z-index: -1;
}

/* Main Container */
#main-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 2rem;
    position: relative;
}

/* Top Bar */
#top-bar {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    display: flex;
    gap: 1rem;
    z-index: 100;
}

.icon-button {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.icon-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0) 100%);
    opacity: 0;
    transition: var(--transition);
}

.icon-button:hover {
    background: var(--bg-primary);
    transform: scale(1.1) translateY(-2px);
    box-shadow: var(--shadow-hover), var(--shadow-glow);
    border-color: var(--accent-color);
}

.icon-button:hover::before {
    opacity: 1;
}

.icon-button:active {
    transform: scale(1.05);
}

/* Modern Settings Button - Liquid Glass */
.settings-button {
    border-radius: 3rem;
    padding: 0.75rem 1.5rem;
    gap: 0.625rem;
    cursor: pointer;
    font-size: 0.9375rem;
    font-weight: 600;
    letter-spacing: 0.025em;
    border: none;
}

.settings-button .glass-content {
    padding: 0;
    gap: 0.625rem;
    justify-content: center;
}

.settings-button svg {
    flex-shrink: 0;
    transition: transform 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.15));
}

.settings-button span {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    white-space: nowrap;
}

.settings-button:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 24px rgba(0, 212, 255, 0.25), 0 0 20px rgba(0, 0, 0, 0.15);
}

.settings-button:hover svg {
    transform: rotate(180deg);
}

.settings-button:active {
    transform: translateY(-1px) scale(1);
}

/* Greeting Section */
#greeting-section {
    text-align: center;
    margin-bottom: 1rem;
}

#greeting-text {
    font-size: 3rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

#greeting-name {
    font-size: 3rem;
    font-weight: 600;
    outline: none;
    min-width: 100px;
    display: inline-block;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    border-bottom: 2px solid transparent;
    transition: var(--transition);
}

#greeting-name:focus {
    border-bottom-color: var(--accent-color);
}

#greeting-name:empty:before {
    content: attr(data-placeholder);
    color: var(--text-tertiary);
}

/* Clock Section */
#clock-section {
    margin-bottom: 3rem;
    text-align: center;
}

#digital-clock time {
    font-size: 5rem;
    font-weight: 300;
    letter-spacing: -0.02em;
    display: block;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

#date-display {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.3);
}

/* Analog Clock */
#analog-clock {
    width: 200px;
    height: 200px;
    margin: 0 auto;
}

.analog-face {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 4px 15px rgba(0, 0, 0, 0.3));
}

#analog-clock line,
#analog-clock circle {
    color: var(--text-primary);
}

/* Weather Section */
#weather-section {
    margin-bottom: 2rem;
    animation: fadeIn 0.8s ease-out 0.35s backwards;
}

#weather-widget {
    border-radius: 3rem;
    padding: 0;
    border: none;
    display: inline-flex;
    transition: var(--transition);
}

#weather-widget .glass-content {
    padding: 1rem 2rem;
    gap: 1rem;
    font-size: 1rem;
}

#weather-widget:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 24px rgba(0, 212, 255, 0.2), 0 0 20px rgba(0, 0, 0, 0.15);
}

#weather-icon {
    font-size: 1.5rem;
}

/* Search Section */
#search-section {
    width: 100%;
    max-width: 600px;
    margin-bottom: 3rem;
}

#search-form {
    position: relative;
    width: 100%;
    border-radius: 3rem;
    overflow: hidden;
}

#search-input {
    width: 100%;
    padding: 1.25rem 3.5rem 1.25rem 1.75rem;
    background: transparent;
    border: none;
    font-size: 1.125rem;
    color: var(--text-primary);
    transition: var(--transition);
    outline: none;
    position: relative;
    z-index: 10;
}

#search-form:focus-within {
    transform: translateY(-2px) scale(1.01);
    box-shadow: 0 12px 40px rgba(0, 212, 255, 0.25), 0 0 30px rgba(0, 0, 0, 0.2);
}

#search-input::placeholder {
    color: var(--text-tertiary);
}

#search-button {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: var(--transition);
    z-index: 10;
}

#search-button:hover {
    background: rgba(0, 0, 0, 0.1);
    color: var(--text-primary);
}

/* Quick Links Section */
#links-section {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    max-width: 800px;
}

#quick-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.quick-link {
    border-radius: 1.5rem;
    padding: 0;
    border: none;
    text-decoration: none;
    color: var(--text-primary);
    min-width: 110px;
    transition: var(--transition-bounce);
    position: relative;
}

.quick-link .glass-content {
    padding: 1.25rem;
    flex-direction: column;
    gap: 0.75rem;
    justify-content: center;
}

.quick-link:hover {
    transform: translateY(-8px) scale(1.05);
    box-shadow: 0 12px 32px rgba(0, 212, 255, 0.3), 0 0 20px rgba(0, 0, 0, 0.2);
}

.link-icon {
    font-size: 2rem;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.link-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.link-name {
    font-size: 0.875rem;
    text-align: center;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-delete {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(255, 59, 48, 0.9);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: bold;
    z-index: 10;
    transition: transform 0.2s ease;
}

.quick-link:hover .link-delete {
    display: flex;
}

.link-delete:hover {
    transform: scale(1.1);
    background: rgba(255, 59, 48, 1);
}

/* Settings Modal */
.settings-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.settings-modal:not(.hidden) {
    opacity: 1;
    pointer-events: all;
}

.settings-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.settings-modal-content {
    position: relative;
    width: 95%;
    max-width: 600px;
    max-height: 90vh;
    background: var(--bg-primary);
    backdrop-filter: blur(var(--blur-strong));
    -webkit-backdrop-filter: blur(var(--blur-strong));
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    overflow: hidden;
}

.settings-modal:not(.hidden) .settings-modal-content {
    transform: scale(1);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: scale(0.9) translateY(20px);
        opacity: 0;
    }
    to {
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

/* Settings Tabs */
.settings-tabs {
    display: flex;
    gap: 0.5rem;
    padding: 1rem;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--glass-border);
    overflow-x: auto;
}

.settings-tab {
    flex: 1;
    min-width: 90px;
    min-height: 70px;
    padding: 0.75rem 0.5rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 12px;
    color: var(--text-tertiary);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    font-size: 0.7rem;
    font-weight: 500;
    position: relative;
}

.settings-tab svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    transition: var(--transition);
}

.settings-tab span {
    white-space: nowrap;
}

.settings-tab:hover {
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border-color: var(--glass-border);
}

.settings-tab.active {
    background: var(--bg-secondary);
    color: var(--accent-color);
    border-color: var(--accent-color);
    box-shadow: 0 4px 16px var(--accent-glow);
}

.settings-tab.active svg {
    filter: drop-shadow(0 0 8px var(--accent-glow));
}

/* Settings Tab Content */
.settings-tab-content {
    display: none;
    animation: fadeSlideIn 0.4s ease-out;
}

.settings-tab-content.active {
    display: block;
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--glass-border);
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
}

.settings-title h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    background: linear-gradient(135deg, var(--accent-color) 0%, #00a8cc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.settings-subtitle {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    margin: 0.25rem 0 0 0;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.settings-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 1.5rem;
}

.settings-section {
    margin-bottom: 2rem;
}

.settings-section:last-child {
    margin-bottom: 0;
}

.settings-section h3 {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-tertiary);
    margin-bottom: 0.75rem;
    padding: 0 0.5rem;
}

.setting-item {
    margin-bottom: 0.5rem;
    background: var(--bg-secondary);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 0.875rem;
    transition: var(--transition);
    max-width: 100%;
    box-sizing: border-box;
    overflow: visible;
}

.setting-item:hover {
    border-color: var(--accent-color);
    background: var(--bg-primary);
    transform: translateX(4px);
}

.setting-item:last-child {
    margin-bottom: 0;
}

/* Row layout for simple controls */
.setting-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: 100%;
}

.setting-label {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.setting-item .setting-label > label {
    display: block;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-primary);
    margin: 0;
    cursor: pointer;
}

.setting-description {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    margin: 0.25rem 0 0 0;
    line-height: 1.4;
}

.setting-control {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

/* Full width controls */
.setting-item.full-width label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.625rem;
}

.setting-item input[type="text"],
.setting-item input[type="url"],
.setting-item input[type="color"],
.setting-item select,
.setting-item textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    font-size: 0.9375rem;
    color: var(--text-primary);
    outline: none;
    transition: var(--transition);
}

.setting-item select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%2300d4ff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.setting-item input:focus,
.setting-item select:focus,
.setting-item textarea:focus {
    background: var(--bg-primary);
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Modern Toggle Switch */
.toggle-switch {
    position: relative;
    width: 48px;
    height: 28px;
    background: var(--bg-tertiary);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    cursor: pointer;
    transition: var(--transition);
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 22px;
    height: 22px;
    background: var(--text-tertiary);
    border-radius: 50%;
    transition: var(--transition);
}

input[type="checkbox"]:checked + .toggle-switch {
    background: var(--accent-color);
    border-color: var(--accent-color);
    box-shadow: 0 0 12px var(--accent-glow);
}

input[type="checkbox"]:checked + .toggle-switch::after {
    transform: translateX(20px);
    background: #ffffff;
}

.setting-item input[type="checkbox"] {
    display: none;
}

.setting-item small {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-tertiary);
    line-height: 1.4;
}

.setting-item small a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
}

.setting-item small a:hover {
    text-decoration: underline;
}

/* Buttons */
.btn-primary,
.btn-secondary,
.btn-danger {
    padding: 0.875rem 1.75rem;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.btn-primary::before,
.btn-secondary::before,
.btn-danger::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, transparent 100%);
    opacity: 0;
    transition: var(--transition);
}

.btn-primary:hover::before,
.btn-secondary:hover::before,
.btn-danger:hover::before {
    opacity: 1;
}

.btn-primary {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

.btn-primary:hover {
    box-shadow: 0 4px 16px var(--accent-glow);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--glass-border);
    margin-right: 0.5rem;
}

.btn-secondary:hover {
    background: var(--bg-primary);
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

.btn-danger {
    background: #ff3b30;
    color: white;
    border-color: #ff3b30;
}

.btn-danger:hover {
    box-shadow: 0 4px 16px rgba(255, 59, 48, 0.5);
    transform: translateY(-2px);
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.modal:not(.hidden) {
    opacity: 1;
    pointer-events: all;
}

.modal:not(.hidden) .modal-content {
    animation: scaleIn 0.4s ease-out;
}

.modal-content {
    background: var(--bg-primary);
    backdrop-filter: blur(var(--blur-strong));
    -webkit-backdrop-filter: blur(var(--blur-strong));
    border: 1px solid var(--glass-border);
    padding: 2.5rem;
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 450px;
    box-shadow: var(--shadow-hover);
}

.modal-content h3 {
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.form-group input {
    width: 100%;
    padding: 0.875rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    font-size: 1rem;
    color: var(--text-primary);
    outline: none;
    transition: var(--transition);
}

.form-group input:focus {
    background: var(--bg-primary);
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px var(--accent-glow);
    transform: translateY(-1px);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-top: 2rem;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    #greeting-text,
    #greeting-name {
        font-size: 2rem;
    }

    #digital-clock time {
        font-size: 3.5rem;
    }

    #date-display {
        font-size: 1rem;
    }

    #settings-panel {
        max-width: 100%;
    }

    .quick-link {
        min-width: 80px;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

#clock-section {
    animation: slideInUp 0.8s ease-out 0.1s backwards;
}

#greeting-section {
    animation: slideInUp 0.8s ease-out 0.2s backwards;
}

#search-section {
    animation: scaleIn 0.6s ease-out 0.3s backwards;
}

#links-section {
    animation: fadeIn 0.8s ease-out 0.4s backwards;
}

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

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

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

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

/* Popular Sites Grid */
.popular-site-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    padding: 0.75rem 0.5rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-primary);
}

.popular-site-btn:hover {
    background: var(--bg-primary);
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

.popular-site-btn .site-icon {
    font-size: 1.5rem;
}

.popular-site-btn .site-name {
    font-weight: 500;
}

/* Toast Notifications */
#toast-container {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    pointer-events: none;
}

.toast {
    background: var(--bg-primary);
    backdrop-filter: blur(var(--blur-strong));
    -webkit-backdrop-filter: blur(var(--blur-strong));
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    min-width: 250px;
    max-width: 400px;
    box-shadow: var(--shadow-hover);
    pointer-events: all;
    animation: toastSlideIn 0.3s ease-out;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.toast.success {
    border-color: #00d4ff;
    box-shadow: 0 4px 16px rgba(0, 212, 255, 0.3);
}

.toast.error {
    border-color: #ff3b30;
    box-shadow: 0 4px 16px rgba(255, 59, 48, 0.3);
}

.toast.info {
    border-color: var(--accent-color);
}

.toast-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.toast-message {
    flex: 1;
    font-size: 0.9375rem;
    color: var(--text-primary);
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-tertiary);
    cursor: pointer;
    padding: 0;
    font-size: 1.25rem;
    line-height: 1;
    opacity: 0.7;
    transition: var(--transition);
}

.toast-close:hover {
    opacity: 1;
}

@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.toast.toast-out {
    animation: toastSlideOut 0.3s ease-out forwards;
}

@keyframes toastSlideOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(100px);
    }
}

/* Confirmation Dialog */
.confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.confirm-overlay.active {
    opacity: 1;
}

.confirm-dialog {
    border-radius: 1.5rem;
    padding: 0;
    min-width: 320px;
    max-width: 400px;
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.confirm-overlay.active .confirm-dialog {
    transform: scale(1);
}

.confirm-dialog .glass-content {
    padding: 2rem;
}

.confirm-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.confirm-icon {
    font-size: 3rem;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 152, 0, 0.15);
    border-radius: 50%;
}

.confirm-message {
    font-size: 1.125rem;
    font-weight: 500;
    text-align: center;
    color: var(--text-primary);
    margin: 0;
}

.confirm-actions {
    display: flex;
    gap: 1rem;
    width: 100%;
}

.confirm-actions button {
    flex: 1;
    padding: 0.875rem 1.5rem;
    border-radius: 12px;
    font-size: 0.9375rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
    background: var(--bg-secondary);
    transform: translateY(-1px);
}

.btn-danger {
    background: linear-gradient(135deg, #ff3b30 0%, #d32f2f 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(255, 59, 48, 0.3);
}

.btn-danger:hover {
    box-shadow: 0 6px 20px rgba(255, 59, 48, 0.4);
    transform: translateY(-1px);
}

.btn-danger:active,
.btn-secondary:active {
    transform: translateY(0);
}
