/* ================================
   bychudy.com-INSPIRED PORTFOLIO
   Creative scattered cards with macOS dock
   ================================ */

/* ================================
   CSS RESET & BASE
   ================================ */

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

/* ================================
   DESIGN TOKENS
   ================================ */

:root {
    /* Background */
    --bg-warm-white: #F5F5F0;
    --bg-card: #FFFFFF;

    /* Text */
    --text-primary: #1A1A1A;
    --text-secondary: #666666;
    --text-muted: #999999;
    --text-light: #CCCCCC;

    /* Accent - Royal Blue */
    --accent-pink: #4169E1;
    --accent-pink-light: #6495ED;
    --accent-pink-glow: rgba(65, 105, 225, 0.3);
    --accent-pink-subtle: rgba(65, 105, 225, 0.1);

    /* macOS Traffic Lights */
    --macos-red: #FF5F56;
    --macos-yellow: #FFBD2E;
    --macos-green: #27C93F;

    /* Shadows */
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-card-hover: 0 12px 40px rgba(0, 0, 0, 0.15);
    --shadow-dock: 0 8px 32px rgba(0, 0, 0, 0.12);
    --shadow-modal: 0 25px 80px rgba(0, 0, 0, 0.25);

    /* Typography */
    --font-system: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif;

    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ================================
   BASE STYLES
   ================================ */

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-system);
    color: var(--text-primary);
    background-color: #1a1a2e; /* Dark fallback while wallpaper loads */
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Skip Link for Accessibility */
.skip-link {
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 24px;
    background: var(--accent-pink);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-md);
    z-index: 100000;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 20px;
}

/* ================================
   CANVAS - FULL VIEWPORT CONTAINER
   ================================ */

.canvas {
    position: relative;
    width: 100%;
    min-height: 100vh;
    padding: var(--spacing-xl);
    padding-bottom: 120px; /* Space for dock */
    overflow: hidden;
}

/* ================================
   DYNAMIC WALLPAPER BACKGROUND
   ================================ */

.dynamic-wallpaper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.dynamic-wallpaper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 2s ease-in-out;
}

.dynamic-wallpaper img.active {
    opacity: 1;
}

/* ================================
   PORTRAIT BACKGROUND (Legacy - hidden)
   ================================ */

.portrait-bg {
    display: none; /* Hidden - replaced by dynamic wallpaper */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60vw;
    height: 90vh;
    max-width: 600px;
    max-height: 800px;
    pointer-events: none;
    z-index: 0;

    /* Placeholder silhouette gradient */
    background: radial-gradient(
        ellipse 50% 70% at 50% 40%,
        rgba(26, 26, 26, 0.08) 0%,
        rgba(26, 26, 26, 0.04) 40%,
        transparent 70%
    );
}

/* ================================
   NAME OVERLAY (removed)
   ================================ */

/* ================================
   macOS FOLDER CARDS
   ================================ */

.project-card {
    position: absolute;
    width: 90px;
    background: transparent;
    cursor: grab;
    z-index: 10;
    text-align: center;
    transition: transform var(--transition-base);
    user-select: none;
}

.project-card:hover {
    transform: perspective(1000px) rotateX(-2deg) rotateY(3deg) scale(1.08);
    z-index: 100;
    box-shadow:
        0 25px 50px rgba(0, 0, 0, 0.15),
        0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Dragging state */
.project-card.dragging {
    cursor: grabbing;
    transform: scale(1.05);
    z-index: 1000;
    transition: none;
}

/* Folder Shape */
.card-thumbnail {
    position: relative;
    width: 72px;
    height: 60px;
    margin: 0 auto 6px;
    background: linear-gradient(180deg, #6CB4F8 0%, #3A98F0 100%);
    border-radius: 3px 10px 6px 6px;
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

/* Folder Tab */
.card-thumbnail::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 3px;
    width: 24px;
    height: 10px;
    background: linear-gradient(180deg, #6CB4F8 0%, #4BA3F5 100%);
    border-radius: 3px 3px 0 0;
}

/* Folder Front Face */
.card-thumbnail::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 3px;
    right: 3px;
    bottom: 3px;
    background: linear-gradient(180deg, #5AACF5 0%, #2C8DE8 100%);
    border-radius: 2px 5px 4px 4px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

/* Icon inside folder */
.card-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -40%);
    font-size: 26px;
    z-index: 2;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.25));
}

/* Folder Label */
.card-title {
    display: inline-block;
    font-size: 11px;
    font-weight: 500;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
    padding: 2px 8px;
    border-radius: 3px;
    background: rgba(0, 0, 0, 0.45);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Global focus-visible for keyboard navigation */
:focus-visible {
    outline: 2px solid var(--accent-pink);
    outline-offset: 3px;
    border-radius: 4px;
}

/* Remove outline for mouse users */
:focus:not(:focus-visible) {
    outline: none;
}

/* Card-specific focus */
.project-card:focus-visible {
    outline: 3px solid var(--accent-pink);
    outline-offset: 4px;
}

/* Button focus */
.modal-link:focus-visible,
.project-link:focus-visible,
.dock-icon:focus-visible {
    outline: 2px solid white;
    outline-offset: 2px;
}

/* Selected state */
.project-card:focus .card-title,
.project-card.selected .card-title {
    background: #0A6EDB;
}

/* Hide category (not used in folder view) */
.card-category {
    display: none;
}

/* Card entrance animation */
.project-card {
    opacity: 0;
    animation: cardFadeIn 0.6s ease forwards;
}

.project-card:nth-child(1) { animation-delay: 0.1s; }
.project-card:nth-child(2) { animation-delay: 0.15s; }
.project-card:nth-child(3) { animation-delay: 0.2s; }
.project-card:nth-child(4) { animation-delay: 0.25s; }
.project-card:nth-child(5) { animation-delay: 0.3s; }
.project-card:nth-child(6) { animation-delay: 0.35s; }
.project-card:nth-child(7) { animation-delay: 0.4s; }
.project-card:nth-child(8) { animation-delay: 0.45s; }
.project-card:nth-child(9) { animation-delay: 0.5s; }
.project-card:nth-child(10) { animation-delay: 0.55s; }
.project-card:nth-child(11) { animation-delay: 0.6s; }
.project-card:nth-child(12) { animation-delay: 0.65s; }
.project-card:nth-child(13) { animation-delay: 0.7s; }
.project-card:nth-child(14) { animation-delay: 0.75s; }
.project-card:nth-child(15) { animation-delay: 0.8s; }
.project-card:nth-child(16) { animation-delay: 0.85s; }
.project-card:nth-child(17) { animation-delay: 0.9s; }
.project-card:nth-child(18) { animation-delay: 0.95s; }
.project-card:nth-child(19) { animation-delay: 1s; }
.project-card:nth-child(20) { animation-delay: 1.05s; }

@keyframes cardFadeIn {
    from {
        opacity: 0;
        transform: rotate(var(--rotation, 0deg)) scale(0.8) translateY(20px);
    }
    to {
        opacity: 1;
        transform: rotate(var(--rotation, 0deg)) scale(1) translateY(0);
    }
}

/* ================================
   macOS DOCK
   ================================ */

.dock {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;

    /* Apple Liquid Glass Effect */
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0.25) 0%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.15) 100%
    );
    backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    -webkit-backdrop-filter: blur(16px) saturate(200%) brightness(110%);

    /* Sharp glass edge */
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    border-radius: 22px;

    /* Liquid Glass shadows: floating effect + specular highlights */
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.12),
        0 12px 48px rgba(0, 0, 0, 0.08),
        inset 0 1px 1px rgba(255, 255, 255, 0.8),
        inset 0 -1px 1px rgba(255, 255, 255, 0.2),
        inset 0 0 20px rgba(255, 255, 255, 0.1);

    padding: 10px 16px;
    display: flex;
    align-items: flex-end;
    gap: 8px;
}


.dock-icon {
    width: 52px;
    height: 52px;
    background: transparent;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    color: var(--text-primary);
    text-decoration: none;
    position: relative;
    z-index: 2;

    /* Spring animation for liquid feel */
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dock-icon svg {
    width: 24px;
    height: 24px;
}

/* Hovered icon scales largest */
.dock-icon:hover {
    transform: scale(1.3) translateY(-10px);
}

/* Left neighbor scales medium (using :has()) */
.dock-icon:has(+ .dock-icon:hover) {
    transform: scale(1.15) translateY(-4px);
}

/* Right neighbor scales medium */
.dock-icon:hover + .dock-icon {
    transform: scale(1.15) translateY(-4px);
}

/* Second-degree left neighbor for smoother wave */
.dock-icon:has(+ .dock-icon + .dock-icon:hover) {
    transform: scale(1.05) translateY(-1px);
}

/* Second-degree right neighbor for smoother wave */
.dock-icon:hover + .dock-icon + .dock-icon {
    transform: scale(1.05) translateY(-1px);
}

.dock-icon:hover svg {
    color: var(--accent-pink);
    filter: drop-shadow(0 0 8px rgba(65, 105, 225, 0.4));
}

/* Dock Label (shown on hover) */
.dock-label {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);

    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    font-weight: 500;
    white-space: nowrap;

    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-fast);
}

.dock-icon:hover .dock-label {
    opacity: 1;
}

/* Dock Divider */
.dock-divider {
    width: 1px;
    height: 32px;
    background: rgba(0, 0, 0, 0.1);
    margin: 0 4px;
    align-self: center;
}

/* ================================
   macOS APP ICON STYLES
   ================================ */

/* Base app icon container (squircle) */
.app-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px; /* fallback for older browsers */
    clip-path: url(#squircle); /* macOS squircle shape */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: transform 0.2s ease;
}

/* Notes Icon - Yellow notepad */
.notes-icon {
    background: linear-gradient(180deg, #FFD60A 0%, #FF9F0A 100%);
}

.notes-lines {
    width: 24px;
    height: 20px;
    background: repeating-linear-gradient(
        180deg,
        transparent 0px,
        transparent 4px,
        rgba(255, 255, 255, 0.6) 4px,
        rgba(255, 255, 255, 0.6) 5px
    );
    border-radius: 2px;
}

/* LinkedIn Icon - Brand blue */
.linkedin-icon {
    background: linear-gradient(180deg, #0A66C2 0%, #004182 100%);
}

/* GitHub Icon - Dark with white logo */
.github-icon {
    background: linear-gradient(180deg, #24292F 0%, #0D1117 100%);
}

/* Terminal Icon - Black with green text */
.terminal-icon {
    background: linear-gradient(180deg, #1C1C1E 0%, #000000 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.terminal-prompt {
    font-family: 'SF Mono', 'Monaco', 'Menlo', monospace;
    font-size: 14px;
    font-weight: 600;
    color: #30D158;
    text-shadow: 0 0 8px rgba(48, 209, 88, 0.5);
}

/* Mail Icon - Blue gradient */
.mail-icon {
    background: linear-gradient(180deg, #34AADC 0%, #007AFF 100%);
}

/* Phone Icon - Green gradient */
.phone-icon {
    background: linear-gradient(180deg, #34C759 0%, #248A3D 100%);
}

/* Trash Icon - Gray */
.trash-icon {
    background: linear-gradient(180deg, #636366 0%, #48484A 100%);
}

/* Hover enhancement for app icons */
.dock-icon:hover .app-icon {
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Update dock-icon for app style */
.dock-icon-app {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

/* ================================
   MODAL
   ================================ */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;

    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);

    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl);

    opacity: 0;
    visibility: hidden;
    transition:
        opacity var(--transition-base),
        visibility var(--transition-base);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-window {
    width: 100%;
    max-width: 600px;
    max-height: 80vh;
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-modal);
    overflow: hidden;

    transform: scale(0.9) translateY(20px);
    transition: transform var(--transition-base);
}

.modal-overlay.active .modal-window {
    transform: scale(1) translateY(0);
}

/* Modal Titlebar */
.modal-titlebar {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: 14px 16px;
    background: #F6F6F6;
    border-bottom: 1px solid #E5E5E5;
}

/* Traffic Lights */
.traffic-lights {
    display: flex;
    gap: 8px;
}

.traffic-light {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    transition: filter var(--transition-fast);
}

.traffic-light:hover {
    filter: brightness(1.1);
}

.traffic-light.red {
    background: var(--macos-red);
}

.traffic-light.yellow {
    background: var(--macos-yellow);
}

.traffic-light.green {
    background: var(--macos-green);
}

.modal-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    flex: 1;
    text-align: center;
    padding-right: 44px; /* Balance the traffic lights */
}

/* Modal Content */
.modal-content {
    padding: var(--spacing-xl);
    overflow-y: auto;
    max-height: calc(80vh - 50px);
}

.modal-image {
    width: 100%;
    height: 200px;
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

.modal-content h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
}

.modal-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
}

.modal-status.active {
    background: rgba(52, 199, 89, 0.12);
    color: #34C759;
}

.modal-status.sold {
    background: rgba(175, 82, 222, 0.12);
    color: #AF52DE;
}

.modal-status.service {
    background: rgba(0, 122, 255, 0.12);
    color: #007AFF;
}

.modal-description {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.modal-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
}

.modal-tag {
    padding: 6px 14px;
    background: rgba(0, 0, 0, 0.04);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.modal-link {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: 12px 24px;
    background: var(--accent-pink);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 600;
    transition: all var(--transition-fast);
}

.modal-link:hover {
    background: var(--accent-pink-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(65, 105, 225, 0.3);
}

/* Button press states */
.modal-link:active,
.project-link:active,
.service-cta:active,
.contact-btn:active,
.book-call-btn:active {
    transform: translateY(0) scale(0.97);
    transition: transform 0.1s ease;
}

.modal-link svg {
    width: 16px;
    height: 16px;
}

/* ================================
   MODAL CONTENT SECTIONS
   ================================ */

/* About Section */
.about-section {
    padding: 0;
}

.about-header {
    display: flex;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.about-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.about-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.about-avatar-icon {
    font-size: 2.5rem;
}

.about-intro h2 {
    margin-bottom: 4px;
}

.about-title {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.about-location {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.about-bio {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.about-stats {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.about-stat {
    flex: 1;
    text-align: center;
    padding: var(--spacing-md);
    background: rgba(0, 0, 0, 0.03);
    border-radius: var(--radius-md);
}

.stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-pink);
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* AI Tool Stack */
.ai-tool-stack {
    margin-bottom: var(--spacing-lg);
}

.ai-tool-stack h4 {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-md);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tool-category {
    margin-bottom: var(--spacing-md);
}

.category-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-pink);
    margin-bottom: var(--spacing-xs);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.tool-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tool-tag {
    padding: 4px 10px;
    background: rgba(65, 105, 225, 0.1);
    border: 1px solid rgba(65, 105, 225, 0.2);
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.about-companies {
    margin-bottom: var(--spacing-lg);
}

.about-companies h4 {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-sm);
}

.company-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
}

.company-tag {
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
}

/* Company Logos */
.company-logos {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-md);
    align-items: center;
    justify-content: flex-start;
}

.company-logo {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 4px;
    padding: 8px;
    box-sizing: border-box;
}

.company-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all var(--transition-fast);
}

.company-logo:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

/* Highlight the current company (first in the list) */
.company-logo-current {
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 0 0 2px var(--accent-blue, #1f3a5f);
    position: relative;
}

.company-logo-current img {
    filter: grayscale(0%);
    opacity: 1;
}

.company-logo-current::after {
    content: 'Current';
    position: absolute;
    bottom: -16px;
    left: 50%;
    transform: translateX(-50%);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.6rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--accent-blue, #1f3a5f);
    white-space: nowrap;
}

.about-testimonials {
    margin-bottom: var(--spacing-lg);
}

.about-testimonials h4 {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-md);
}

.testimonial {
    padding: var(--spacing-md);
    background: rgba(0, 0, 0, 0.02);
    border-left: 3px solid var(--accent-pink);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    margin-bottom: var(--spacing-md);
}

.testimonial-quote {
    font-style: italic;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-sm);
    line-height: 1.6;
}

.testimonial-author {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.about-contact {
    display: flex;
    gap: var(--spacing-sm);
    flex-wrap: wrap;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: 10px 16px;
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-primary);
    text-decoration: none;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.contact-btn:hover {
    background: rgba(0, 0, 0, 0.1);
}

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

.contact-btn.primary:hover {
    background: var(--accent-pink-light);
}

/* Projects Section */
.projects-section {
    padding: 0;
}

.project-tabs {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding-bottom: var(--spacing-sm);
}

.project-tab {
    padding: 8px 16px;
    background: none;
    border: none;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.project-tab:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-primary);
}

.project-tab.active {
    background: var(--accent-pink);
    color: white;
}

.project-panel {
    display: none;
}

.project-panel.active {
    display: block;
}

.project-hero {
    height: 150px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--spacing-lg);
}

.project-icon {
    font-size: 3rem;
}

.project-details {
    padding: 0;
}

.project-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
}

.project-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
}

.project-status {
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 600;
}

.project-status.active {
    background: rgba(52, 199, 89, 0.12);
    color: #34C759;
}

.project-status.sold {
    background: rgba(175, 82, 222, 0.12);
    color: #AF52DE;
}

.project-description {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: var(--spacing-md);
}

.project-metrics {
    padding: var(--spacing-sm) var(--spacing-md);
    background: rgba(52, 199, 89, 0.08);
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    color: #34C759;
    margin-bottom: var(--spacing-md);
}

.project-tech {
    margin-bottom: var(--spacing-md);
}

.project-tech h4 {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-sm);
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
}

.tech-tag {
    padding: 4px 10px;
    background: rgba(0, 122, 255, 0.1);
    color: #007AFF;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-md);
}

.project-link {
    display: inline-flex;
    align-items: center;
    padding: 10px 20px;
    background: var(--accent-pink);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.project-link:hover {
    background: var(--accent-pink-light);
    transform: translateY(-2px);
}

/* Work History Section */
.work-section {
    padding: 0;
}

.work-timeline {
    position: relative;
    padding-left: 24px;
}

.work-timeline::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(0, 0, 0, 0.1);
}

.work-item {
    position: relative;
    padding-bottom: var(--spacing-lg);
}

.work-item:last-child {
    padding-bottom: 0;
}

.work-marker {
    position: absolute;
    left: -24px;
    top: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.work-content {
    padding-left: var(--spacing-sm);
}

.work-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 2px;
}

.work-header h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.work-period {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.work-role {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 2px;
}

.work-location {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-xs);
}

.work-description {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-xs);
}

.work-achievement {
    font-size: 0.8rem;
    color: var(--accent-pink);
    font-weight: 500;
}

.work-footer {
    margin-top: var(--spacing-lg);
    padding-top: var(--spacing-md);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

/* Services Section */
.services-section {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.service-card {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.service-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    color: white;
}

.service-icon {
    font-size: 1.5rem;
}

.service-header h3 {
    font-size: 1rem;
    font-weight: 600;
}

.service-body {
    padding: var(--spacing-md);
}

.service-description {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: var(--spacing-md);
}

.service-includes {
    margin-bottom: var(--spacing-md);
}

.service-includes h4 {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-sm);
}

.service-includes ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.service-includes li {
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 4px 0;
    padding-left: 20px;
    position: relative;
}

.service-includes li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #34C759;
}

.service-ideal {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-md);
}

.service-cta {
    display: inline-block;
    padding: 10px 20px;
    background: var(--accent-pink);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.service-cta:hover {
    background: var(--accent-pink-light);
    transform: translateY(-2px);
}

/* Metrics Section */
.metrics-section {
    padding: 0;
}

.metrics-intro {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.metric-card {
    text-align: center;
    padding: var(--spacing-lg);
    background: rgba(0, 0, 0, 0.02);
    border-radius: var(--radius-md);
    border-left: 4px solid;
}

.metric-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.metric-label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.metrics-details {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.metric-detail {
    padding: var(--spacing-md);
    background: rgba(0, 0, 0, 0.02);
    border-radius: var(--radius-md);
}

.metric-detail h4 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-xs);
}

.metric-detail p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Book a Call Section */
.book-call-section {
    text-align: center;
    padding: var(--spacing-lg) 0;
}

.book-call-icon {
    font-size: 4rem;
    margin-bottom: var(--spacing-md);
}

.book-call-section h2 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
}

.book-call-intro {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.book-call-options {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
}

.book-call-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: 14px 24px;
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-primary);
    text-decoration: none;
    border-radius: var(--radius-full);
    font-size: 0.95rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.book-call-btn:hover {
    background: rgba(0, 0, 0, 0.1);
}

.book-call-btn.primary {
    background: var(--accent-pink);
    color: white;
}

.book-call-btn.primary:hover {
    background: var(--accent-pink-light);
}

.book-call-availability {
    padding: var(--spacing-md);
    background: rgba(0, 0, 0, 0.02);
    border-radius: var(--radius-md);
}

.book-call-availability h4 {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
}

.book-call-availability p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin: 0;
}

/* ================================
   NOW SECTION (current quarter snapshot)
   ================================ */

.now-section {
    padding: var(--spacing-md) 0;
}

.now-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: var(--spacing-lg);
}

.now-pulse {
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    margin-top: 8px;
    border-radius: 50%;
    background: #34C759;
    box-shadow: 0 0 0 4px rgba(52, 199, 89, 0.18);
    animation: now-pulse 1.8s ease-in-out infinite;
}

@keyframes now-pulse {
    0%, 100% { box-shadow: 0 0 0 4px rgba(52, 199, 89, 0.18); }
    50%      { box-shadow: 0 0 0 8px rgba(52, 199, 89, 0.05); }
}

.now-section h2 {
    margin: 0 0 4px 0;
    font-size: 1.4rem;
}

.now-meta {
    margin: 0;
    font-size: 0.82rem;
    color: var(--text-secondary, #6b7280);
    letter-spacing: 0.2px;
}

.now-list {
    list-style: none;
    margin: 0 0 var(--spacing-lg) 0;
    padding: 0;
}

.now-item {
    padding: 14px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.now-item:last-child { border-bottom: none; }

.now-item h4 {
    margin: 0 0 4px 0;
    font-size: 0.98rem;
    font-weight: 600;
}

.now-item p {
    margin: 0;
    font-size: 0.92rem;
    color: var(--text-secondary, #4b5563);
    line-height: 1.5;
}

.now-footer {
    margin: 0;
    font-size: 0.78rem;
    color: var(--text-secondary, #6b7280);
    text-align: center;
    padding-top: var(--spacing-md);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.now-footer a { color: var(--text-secondary, #6b7280); text-decoration: underline; }

/* ================================
   WRITING & TALKS SECTION
   ================================ */

.writing-section {
    padding: var(--spacing-md) 0;
}

.writing-section h2 {
    margin: 0 0 8px 0;
    font-size: 1.4rem;
}

.writing-intro {
    margin: 0 0 var(--spacing-lg) 0;
    color: var(--text-secondary, #4b5563);
    line-height: 1.55;
}

.writing-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.writing-item {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 14px;
    align-items: baseline;
    padding: 14px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.writing-item:last-child { border-bottom: none; }

.writing-kind {
    grid-row: 1;
    grid-column: 1;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #1f3a5f;
    padding: 3px 8px;
    background: rgba(31, 58, 95, 0.08);
    border-radius: 4px;
    align-self: start;
    margin-top: 2px;
}

.writing-title {
    grid-row: 1;
    grid-column: 2;
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--text-primary, #14181f);
    text-decoration: none;
}

a.writing-title:hover { text-decoration: underline; }

.writing-where {
    grid-row: 2;
    grid-column: 2;
    font-size: 0.86rem;
    color: var(--text-secondary, #4b5563);
}

.writing-date {
    grid-row: 2;
    grid-column: 1;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.74rem;
    color: var(--text-secondary, #6b7280);
    text-align: right;
}

/* ================================
   MOBILE NAVIGATION
   ================================ */

.nav-mobile {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;

    /* Apple Liquid Glass Effect (Light variant for mobile) */
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.9) 0%,
        rgba(255, 255, 255, 0.95) 100%
    );
    backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    -webkit-backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    border-top: 1.5px solid rgba(255, 255, 255, 0.8);

    padding: 8px 0;
    padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));

    grid-template-columns: repeat(4, 1fr);
    box-shadow:
        0 -4px 24px rgba(0, 0, 0, 0.08),
        inset 0 1px 1px rgba(255, 255, 255, 0.9);
}

.nav-mobile-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px;
    color: var(--text-muted);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.nav-mobile-item:active {
    color: var(--accent-pink);
}

.nav-mobile-icon svg {
    width: 24px;
    height: 24px;
}

.nav-mobile-label {
    font-size: 0.65rem;
    font-weight: 500;
}

/* ================================
   RESPONSIVE DESIGN
   ================================ */

@media (max-width: 1200px) {
    .card-large { width: 180px; }
    .card-medium { width: 140px; }
    .card-small { width: 100px; }
}

@media (max-width: 1024px) {
    .name-overlay h1 {
        font-size: clamp(2.5rem, 6vw, 4rem);
    }

    .dock-icon {
        width: 44px;
        height: 44px;
    }

    .dock-icon svg {
        width: 20px;
        height: 20px;
    }
}

/* Mobile: Left-side dock, stack cards */
@media (max-width: 768px) {
    /* Dock: Move to left side, vertical layout */
    .dock {
        display: flex;
        flex-direction: column;
        align-items: center;

        /* Positioning: left side, vertically centered */
        bottom: auto;
        left: 12px;
        top: 50%;
        transform: translateY(-50%);

        /* Adjust padding for vertical */
        padding: 12px 8px;
        gap: 6px;

        /* Narrower border-radius for vertical pill */
        border-radius: 18px;
    }

    /* Touch-friendly icons on mobile (48px min target) */
    .dock-icon {
        width: 48px;
        height: 48px;
        min-width: 48px;
        min-height: 48px;
    }

    .dock-icon svg,
    .app-icon {
        width: 36px;
        height: 36px;
    }

    .app-icon svg {
        width: 20px;
        height: 20px;
    }

    /* Disable hover magnification on touch devices */
    .dock-icon:hover,
    .dock-icon:has(+ .dock-icon:hover),
    .dock-icon:hover + .dock-icon,
    .dock-icon:has(+ .dock-icon + .dock-icon:hover),
    .dock-icon:hover + .dock-icon + .dock-icon {
        transform: none;
    }

    /* Simple tap feedback instead */
    .dock-icon:active {
        transform: scale(0.95);
    }

    /* Hide labels on mobile (no hover) */
    .dock-label {
        display: none;
    }

    /* Dock divider: horizontal line for vertical dock */
    .dock-divider {
        width: 32px;
        height: 1px;
        margin: 4px 0;
    }

    /* Hide the mobile nav since we're using dock */
    .nav-mobile {
        display: none !important;
    }

    .canvas {
        padding: var(--spacing-md);
        padding-left: 70px; /* Space for left dock */
        padding-bottom: 32px;
        min-height: auto;
        /* Flexbox for 2-column card grid */
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        align-content: flex-start;
    }

    .portrait-bg {
        display: none;
    }

    .name-overlay {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        opacity: 1;
        pointer-events: auto;
        margin-bottom: var(--spacing-md);
        padding-top: var(--spacing-lg);
        /* Full width header */
        width: 100%;
        flex-shrink: 0;
    }

    .name-overlay h1 {
        font-size: 2rem;
    }

    .name-overlay p {
        font-size: 0.9rem;
    }

    /* 2-column card grid */
    .project-card {
        position: relative !important;
        left: auto !important;
        top: auto !important;
        width: calc(50% - 4px) !important;
        margin: 0 !important;
        transform: none !important;
    }

    .project-card:hover {
        transform: scale(1.02) !important;
    }

    .card-thumbnail {
        aspect-ratio: 1;
    }

    /* Modal full-screen on mobile */
    .modal-window {
        max-width: 100%;
        max-height: 100%;
        height: 100%;
        border-radius: 0;
    }

    .modal-overlay {
        padding: 0;
    }

    .modal-content {
        max-height: calc(100vh - 50px);
    }
}

@media (max-width: 480px) {
    /* Single column cards on small phones */
    .project-card {
        width: 100% !important;
    }

    .card-title {
        font-size: 0.8rem;
    }

    .card-icon {
        font-size: 1.5rem;
    }

    .metric-value {
        font-size: 1rem;
    }

    /* Slightly smaller dock padding on phones */
    .canvas {
        padding-left: 60px;
    }

    .dock {
        left: 8px;
        padding: 10px 6px;
    }

    .dock-icon {
        width: 40px;
        height: 40px;
    }

    .app-icon {
        width: 32px;
        height: 32px;
    }
}

/* ================================
   REDUCED MOTION
   ================================ */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .project-card {
        opacity: 1;
        animation: none;
    }

    .project-card:hover {
        transform: rotate(0deg);
    }
}

/* ================================
   UTILITY CLASSES
   ================================ */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ================================
   macOS WIDGETS
   ================================ */

.widget {
    position: fixed;
    width: 180px;
    padding: 16px;

    /* Apple Liquid Glass Effect */
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0.25) 0%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.15) 100%
    );
    backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    -webkit-backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    border-radius: 20px;
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.12),
        0 12px 48px rgba(0, 0, 0, 0.08),
        inset 0 1px 1px rgba(255, 255, 255, 0.8),
        inset 0 -1px 1px rgba(255, 255, 255, 0.2),
        inset 0 0 20px rgba(255, 255, 255, 0.1);

    color: white;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    z-index: 500;
    cursor: grab;
    user-select: none;
}

.widget.dragging {
    cursor: grabbing;
    z-index: 1000;
}

/* World Clock Widget - Centered at top */
.widget-worldclock {
    top: 30px;
    left: 50%;
    transform: translateX(-50%);
    width: 400px;
    padding: 20px;

    /* Apple Liquid Glass Effect */
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0.25) 0%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.15) 100%
    );
    backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    -webkit-backdrop-filter: blur(16px) saturate(200%) brightness(110%);
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.12),
        0 12px 48px rgba(0, 0, 0, 0.08),
        inset 0 1px 1px rgba(255, 255, 255, 0.8),
        inset 0 -1px 1px rgba(255, 255, 255, 0.2),
        inset 0 0 20px rgba(255, 255, 255, 0.1);
}

.worldclock-row {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 16px;
}

.worldclock-row:last-child {
    margin-bottom: 0;
}

.worldclock-city {
    text-align: center;
    width: 85px;
}

.clock-digital {
    font-size: 1.4rem;
    font-weight: 300;
    font-family: -apple-system, 'SF Pro Display', system-ui, sans-serif;
    color: white;
    margin-bottom: 4px;
    letter-spacing: 1px;
}

.clock-label {
    font-size: 0.7rem;
    font-weight: 500;
    color: white;
    margin-bottom: 2px;
}

.clock-offset {
    font-size: 0.55rem;
    color: rgba(255, 255, 255, 0.5);
}

.clock-face {
    width: 70px;
    height: 70px;
    margin: 0 auto 6px;
}

.clock-face svg {
    width: 100%;
    height: 100%;
}

.clock-bg {
    fill: rgba(50, 50, 50, 0.8);
}

.clock-ring {
    fill: none;
    stroke: rgba(255, 255, 255, 0.2);
    stroke-width: 1;
}

.clock-num {
    font-size: 8px;
    fill: rgba(255, 255, 255, 0.6);
    text-anchor: middle;
    dominant-baseline: middle;
}

.hour-hand {
    stroke: white;
    stroke-width: 3;
    stroke-linecap: round;
}

.minute-hand {
    stroke: #FF9500;
    stroke-width: 2;
    stroke-linecap: round;
}

.clock-center {
    fill: #FF9500;
}

/* Day indicator - white face for daytime */
.worldclock-city.is-day .clock-bg {
    fill: rgba(255, 255, 255, 0.9);
}

.worldclock-city.is-day .clock-num {
    fill: rgba(0, 0, 0, 0.6);
}

.worldclock-city.is-day .hour-hand {
    stroke: #333;
}

/* Weather Widget - Square, left of center */
.widget-weather {
    top: 330px;
    left: 50%;
    transform: translateX(-110%);
    width: 160px;
    min-height: 160px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.weather-location {
    font-size: 0.75rem;
    opacity: 0.7;
    margin-bottom: 4px;
}

.weather-icon {
    font-size: 2.5rem;
    margin: 4px 0;
}

.weather-temp {
    font-size: 2rem;
    font-weight: 200;
}

.weather-desc {
    font-size: 0.8rem;
    text-transform: capitalize;
    opacity: 0.8;
}

/* Music Widget - Spotify Embed */
.widget-music {
    top: 30px;
    right: 100px;
    left: auto;
    transform: none;
    width: 300px;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
    border-radius: 12px;
    overflow: hidden;
}

/* Drag handle for widgets with iframes */
.widget-drag-handle {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(30, 30, 30, 0.9);
    border-radius: 12px 12px 0 0;
    cursor: grab;
    user-select: none;
}

.widget-drag-handle:active {
    cursor: grabbing;
}

.widget-drag-handle .drag-dots {
    color: rgba(255, 255, 255, 0.4);
    font-size: 12px;
    letter-spacing: 2px;
}

.widget-drag-handle .widget-title {
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
    font-weight: 500;
}

/* Hide drag handle for music widget - show only the player */
.widget-music .widget-drag-handle {
    display: none;
}

.widget-music iframe {
    display: block;
    border-radius: 12px;
}

.music-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    font-weight: 500;
    font-size: 0.9rem;
}

.music-icon {
    font-size: 1.2rem;
}

.music-track {
    padding: 8px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.music-track:first-child {
    border-top: none;
}

.track-name {
    display: block;
    font-size: 0.8rem;
    font-weight: 500;
}

.track-artist {
    display: block;
    font-size: 0.7rem;
    opacity: 0.7;
}

/* Calendar Widget - Square, right of center */
.widget-calendar {
    top: 330px;
    left: 50%;
    transform: translateX(10%);
    width: 160px;
    min-height: 160px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.calendar-month {
    font-size: 0.75rem;
    opacity: 0.7;
}

.calendar-day {
    font-size: 2.8rem;
    font-weight: 200;
    line-height: 1;
    margin: 6px 0;
}

.calendar-weekday {
    font-size: 0.85rem;
    margin-bottom: 12px;
}

.calendar-book-btn {
    display: block;
    padding: 10px 16px;
    background: rgba(65, 105, 225, 0.9);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 500;
    transition: background 0.2s ease;
}

.calendar-book-btn:hover {
    background: rgba(65, 105, 225, 1);
}

/* ================================
   WORDLE GAME WIDGET
   ================================ */

.widget-wordle {
    top: 350px;
    right: 100px;
    left: auto;
    width: 300px;
    padding: 14px;
}

.wordle-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.wordle-title {
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.wordle-help-btn {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    background: transparent;
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.wordle-help-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.wordle-board {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 14px;
}

.wordle-row {
    display: flex;
    gap: 5px;
    justify-content: center;
}

.wordle-tile {
    width: 48px;
    height: 48px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 700;
    text-transform: uppercase;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    transition: transform 0.1s, border-color 0.1s;
}

.wordle-tile.filled {
    border-color: rgba(255, 255, 255, 0.5);
    animation: wordlePop 0.1s ease;
}

.wordle-tile.correct {
    background: #538d4e;
    border-color: #538d4e;
}

.wordle-tile.present {
    background: #b59f3b;
    border-color: #b59f3b;
}

.wordle-tile.absent {
    background: #3a3a3c;
    border-color: #3a3a3c;
}

.wordle-tile.reveal {
    animation: wordleFlip 0.5s ease forwards;
}

@keyframes wordlePop {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

@keyframes wordleFlip {
    0% { transform: rotateX(0deg); }
    50% { transform: rotateX(90deg); }
    100% { transform: rotateX(0deg); }
}

@keyframes wordleShake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-5px); }
    40% { transform: translateX(5px); }
    60% { transform: translateX(-5px); }
    80% { transform: translateX(5px); }
}

@keyframes wordleBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.wordle-row.shake {
    animation: wordleShake 0.5s ease;
}

.wordle-tile.bounce {
    animation: wordleBounce 0.5s ease;
}

.wordle-message {
    text-align: center;
    font-size: 0.85rem;
    font-weight: 500;
    min-height: 24px;
    margin-top: 10px;
    opacity: 0;
    transition: opacity 0.3s;
}

.wordle-message.show {
    opacity: 1;
}

/* Wordle: header actions group */
.wordle-header-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

.wordle-action-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    color: white;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, opacity 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.wordle-action-btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.7);
}

.wordle-action-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

/* Wordle: on-screen keyboard */
.wordle-keyboard {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 12px;
    user-select: none;
}

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

.wordle-key {
    flex: 1 0 0;
    min-width: 0;
    height: 32px;
    padding: 0 3px;
    border: none;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.18);
    color: white;
    font-size: 0.72rem;
    font-weight: 700;
    font-family: inherit;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s, transform 0.05s;
}

.wordle-key:hover {
    background: rgba(255, 255, 255, 0.28);
}

.wordle-key:active {
    transform: scale(0.95);
}

.wordle-key-wide {
    flex: 1.6 0 0;
    font-size: 0.7rem;
}

.wordle-key.correct { background: #538d4e; color: #fff; }
.wordle-key.present { background: #b59f3b; color: #fff; }
.wordle-key.absent  { background: #3a3a3c; color: rgba(255,255,255,0.55); }

/* Wordle: hint tile glow */
.wordle-tile.hint {
    box-shadow: inset 0 0 0 2px #f5c518;
}

/* Wordle: share button */
.wordle-share {
    text-align: center;
    margin-top: 10px;
}

.wordle-share-btn {
    background: #538d4e;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, transform 0.05s;
}

.wordle-share-btn:hover { background: #69ab63; }
.wordle-share-btn:active { transform: scale(0.97); }

/* Wordle: modal (help / stats) */
.wordle-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.wordle-modal-overlay.active { display: flex; }

.wordle-modal {
    background: #1c1f24;
    color: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    width: min(420px, 92vw);
    max-height: 85vh;
    overflow-y: auto;
    padding: 24px 24px 20px;
    position: relative;
    font-family: inherit;
}

.wordle-modal h2 {
    margin: 0 0 14px;
    font-size: 1.4rem;
}

.wordle-modal h3 {
    font-size: 0.95rem;
    margin: 18px 0 8px;
    color: #c5cad3;
}

.wordle-modal p {
    margin: 0 0 10px;
    font-size: 0.92rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
}

.wordle-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.15s;
}

.wordle-modal-close:hover { background: rgba(255, 255, 255, 0.25); }

.wordle-help-examples {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 14px 0 6px;
}

.wordle-help-row {
    display: flex;
    gap: 4px;
    align-items: center;
    flex-wrap: wrap;
}

.wordle-help-tile {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    border-radius: 3px;
    background: transparent;
}

.wordle-help-tile.correct { background: #538d4e; border-color: #538d4e; }
.wordle-help-tile.present { background: #b59f3b; border-color: #b59f3b; }
.wordle-help-tile.absent  { background: #3a3a3c; border-color: #3a3a3c; }

.wordle-help-text {
    margin-left: 8px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Wordle: stats */
.wordle-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 8px 0 18px;
}

.wordle-stat {
    text-align: center;
}

.wordle-stat-num {
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1;
}

.wordle-stat-label {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.wordle-dist {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.wordle-dist-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.wordle-dist-label {
    width: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
}

.wordle-dist-bar {
    flex: 1;
}

.wordle-dist-fill {
    background: #538d4e;
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    padding: 3px 8px;
    border-radius: 2px;
    text-align: right;
    min-width: 24px;
}

.wordle-stats-note {
    margin-top: 12px;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

/* ================================
   GUEST NOTE (Post-it)
   ================================ */

.guest-note {
    position: fixed;
    top: 400px;
    left: 220px;
    right: auto;
    width: 220px;
    padding: 14px;
    background: #ffeb3b;
    border-radius: 4px;
    box-shadow: 3px 5px 15px rgba(0, 0, 0, 0.25);
    z-index: 600;
    font-family: 'Segoe UI', system-ui, sans-serif;
    cursor: grab;
    user-select: none;
}

.guest-note.dragging {
    cursor: grabbing;
    z-index: 1000;
    box-shadow: 5px 10px 25px rgba(0, 0, 0, 0.35);
}

.guest-note-header {
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(0, 0, 0, 0.6);
    margin-bottom: 10px;
    pointer-events: none;
}

.guest-note-name {
    width: 100%;
    padding: 8px 0;
    border: none;
    border-bottom: 1px dashed rgba(0, 0, 0, 0.2);
    background: transparent;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: inherit;
    color: #333;
    outline: none;
    margin-bottom: 8px;
}

.guest-note-name::placeholder {
    color: rgba(0, 0, 0, 0.35);
    font-weight: 400;
}

.guest-note-content {
    width: 100%;
    min-height: 80px;
    padding: 8px 0;
    border: none;
    background: transparent;
    font-size: 0.9rem;
    font-family: inherit;
    color: #333;
    line-height: 1.5;
    resize: none;
    outline: none;
}

.guest-note-content::placeholder {
    color: rgba(0, 0, 0, 0.35);
}

.guest-note-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
    min-height: 16px;
}

.guest-note-saved {
    font-size: 0.7rem;
    color: rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s;
}

/* ================================
   MARQUEE SELECTION
   ================================ */

.selection-box {
    position: fixed;
    border: 1px dashed rgba(65, 105, 225, 0.8);
    background: rgba(65, 105, 225, 0.1);
    pointer-events: none;
    z-index: 9998;
}

.project-card.selected .card-title {
    background: #0A6EDB;
}

/* Hide widgets on mobile */
@media (max-width: 768px) {
    .widget {
        display: none;
    }

    .guest-note {
        bottom: 80px;
        right: 12px;
        width: 180px;
    }
}
