/* ========================================
   CSS VARIABLES & RESET
   ======================================== */

:root {
    --color-primary: #2563eb;
    --color-primary-dark: #1e40af;
    --color-text: #1f2937;
    --color-text-light: #6b7280;
    --color-background: #ffffff;
    --color-background-alt: #f9fafb;
    --color-border: #e5e7eb;
    --color-border-light: #f3f4f6;
    --color-success: #10b981;
    --color-warning: #f59e0b;
    
    /* New accent colors for tags */
    --color-python: #3b82f6;
    --color-powerbi: #f59e0b;
    --color-ecommerce: #8b5cf6;
    --color-sql: #06b6d4;
    --color-excel: #10b981;
    
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'SF Mono', Monaco, 'Cascadia Code', 'Courier New', monospace;
    
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;
    
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    overflow-x: hidden;
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.7;
    color: var(--color-text);
    background-color: var(--color-background-alt);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ========================================
   TYPOGRAPHY
   ======================================== */

h1, h2, h3, h4, h5, h6 {
    line-height: 1.3;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: var(--spacing-sm);
}

h1 {
    font-size: 2rem;
    letter-spacing: -0.02em;
}

h2 {
    font-size: 1.875rem;
    letter-spacing: -0.01em;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

p {
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--color-primary-dark);
}

strong {
    font-weight: 600;
    color: var(--color-text);
}

.lead {
    font-size: 1.25rem;
    line-height: 1.6;
    color: var(--color-text-light);
    margin-bottom: var(--spacing-lg);
}

/* ========================================
   LAYOUT CONTAINER
   ======================================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

@media (max-width: 768px) {
    .container {
        padding: 0 var(--spacing-md);
    }
}

/* ========================================
   HEADER
   ======================================== */
header{
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 9999;
  padding: 0.625rem 0 0.5rem 0;

  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-bottom: none;
}

/* Rounded bottom for smooth visual flow */
header::after {
  content: '';
  position: absolute;
  bottom: -12px;
  left: 0;
  right: 0;
  height: 12px;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 16px;
  z-index: -1;
}

/* Add padding to body to compensate for fixed header */
body {
    padding-top: calc(48px + 1rem + 12px);
}

.brand-logo {
    height: 48px;
    width: auto;
    display: block;
    transition: none;
    z-index: 2;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-md);
}

.brand {
    position: relative;
    display: flex;
    align-items: center;
    margin-left: 1rem;
}

nav {
    margin-right: 1rem;
    flex-shrink: 0;
}

@media (max-width: 480px) {
    .brand-logo {
        height: 26px;
    }
}

.brand h1 {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
    font-weight: 700;
}

/* Motto visible by default on desktop */
.subtitle {
    position: absolute;
    left: calc(100% + 1rem);
    top: 50%;
    transform: translateY(-50%);
    
    font-family: "Georgia", "Times New Roman", serif;
    font-style: italic;
    font-size: 1rem;
    letter-spacing: 0.06em;
    color: #6b7280;
    
    /* Clean text, no bubble */
    background: none;
    border: none;
    border-radius: 0;
    padding: 0;
    white-space: nowrap;
    box-shadow: none;
    
    /* Visible on desktop */
    opacity: 1;
    pointer-events: auto;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 1;
}

/* Triangle pointers removed — no bubble */
.subtitle::before {
    display: none;
}

.subtitle::after {
    display: none;
}


nav {
    display: flex;
    gap: var(--spacing-xl);
}

nav a {
    color: var(--color-text);
    font-weight: 500;
    font-size: 1.125rem;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--border-radius-sm);
    transition: color 0.3s ease, background-color 0.3s ease;
    text-align: center;
    min-width: 5.5rem;
}

nav a:hover {
    color: var(--color-primary);
    background-color: var(--color-background-alt);
}

nav a.active {
    color: var(--color-primary);
    background-color: rgba(37, 99, 235, 0.1);
}

/* Desktop only - spread navigation to edges */
@media (min-width: 641px) {
    .header-content {
        justify-content: space-between;
    }
    
    nav {
        gap: 1.5rem;
        margin-right: 2rem;
    }
    
    nav a {
        padding: var(--spacing-xs) 0.6rem;
    }
}

/* Medium screens — hide motto only when truly no space */
@media (max-width: 860px) and (min-width: 641px) {
    .subtitle {
        display: none;
    }
    
    nav {
        gap: 1rem;
    }
}

/* ========================================
   MAIN CONTENT
   ======================================== */

/* Mobile & Tablet - Header compact */
@media (max-width: 640px) {
    header {
        padding: 0.5rem 0;
    }
    
    .header-content {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 0.4rem;
        flex-wrap: nowrap;
    }
    
    .brand {
        display: flex;
        align-items: center;
        gap: 0.4rem;
        flex-shrink: 1;
        min-width: 0;
    }
    
    .brand-logo {
        height: 24px;
        flex-shrink: 0;
    }
    
    header:hover .brand-logo {
        height: 24px;
    }
    
    /* Motto inline, ascuns by default */
    .subtitle {
        display: inline-block !important;
        position: static;
        opacity: 0;
        max-width: 0;
        overflow: hidden;
        white-space: nowrap;
        transition: opacity 0.3s ease, max-width 0.3s ease;
        font-size: 0.65rem;
        line-height: 1.2;
        padding: 0;
        margin: 0;
        background: none;
        border: none;
        box-shadow: none;
        color: var(--color-text-light);
        flex-shrink: 1;
    }
    
    .subtitle::before,
    .subtitle::after {
        display: none;
    }
    
    /* Show motto inline on scroll up */
    header.scrolled-up .subtitle {
        opacity: 1;
        max-width: 200px;
    }
    
    nav {
        gap: 0.3rem;
        flex-shrink: 0;
    }
    
    nav a {
        font-size: 0.8125rem;
        padding: 0.4rem 0.65rem;
    }
}

/* Fix mobile footer to bottom */
@media (max-width: 640px) {
    body {
        min-height: 100vh;
    }
    
    main {
        min-height: auto;
    }
    
    .contact-main {
        min-height: calc(100vh - 120px);
    }

.about-main {
    min-height: calc(100vh - 120px);
    overflow-x: hidden;
}
}

/* ========================================
   MAIN CONTENT
   ======================================== */

main {
    padding: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* ========================================
   HERO SECTION
   ======================================== */

.hero {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    padding-top: var(--spacing-lg);
}

.hero h2 {
    font-size: 2.75rem;
    margin-bottom: var(--spacing-sm);
    background: linear-gradient(135deg, var(--color-text) 0%, var(--color-text-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-light);
}

@media (max-width: 640px) {
    .hero h2 {
        font-size: 2rem;
    }
}

/* ========================================
   ANALYSIS CARDS GRID - IMPROVED
   ======================================== */

.analyses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: var(--spacing-xl);
    margin-bottom: var(--spacing-2xl);
}

@media (max-width: 768px) {
    .analyses-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
}

/* link care cuprinde cardul – face cardul clicabil */
.analysis-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* cardul în sine - IMPROVED */
.analysis-card {
    background-color: var(--color-background);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-xl);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* bara colorată de sus - MORE PROMINENT */
.analysis-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* subtle gradient overlay on hover */
.analysis-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.03) 0%, rgba(139, 92, 246, 0.03) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

/* ENHANCED hover effect */
.analysis-card-link:hover .analysis-card {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.15), 0 10px 20px -5px rgba(0, 0, 0, 0.1);
    border-color: rgba(37, 99, 235, 0.3);
}

.analysis-card-link:hover .analysis-card::before {
    transform: scaleX(1);
}

.analysis-card-link:hover .analysis-card::after {
    opacity: 1;
}

.card-header {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-md);
    position: relative;
    z-index: 1;
}

/* IMPROVED TAGS with different colors */
.tag {
    display: inline-block;
    padding: 0.35rem 0.85rem;
    background-color: rgba(37, 99, 235, 0.1);
    color: var(--color-primary);
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    transition: var(--transition);
}

.tag:nth-child(1) {
    background-color: rgba(59, 130, 246, 0.1);
    color: var(--color-python);
}

.tag:nth-child(2) {
    background-color: rgba(245, 158, 11, 0.1);
    color: var(--color-powerbi);
}

.tag:nth-child(3) {
    background-color: rgba(139, 92, 246, 0.1);
    color: var(--color-ecommerce);
}

.analysis-card-link:hover .tag {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.analysis-card h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-xs);
    position: relative;
    z-index: 1;
    transition: var(--transition);
}

.analysis-card-link:hover h3 {
    color: var(--color-primary);
}

.analysis-card h3 a {
    color: var(--color-text);
    transition: var(--transition);
}

.analysis-card h3 a:hover {
    color: var(--color-primary);
}

.analysis-card .date {
    color: var(--color-text-light);
    font-size: 0.875rem;
    margin-bottom: var(--spacing-md);
    display: block;
    position: relative;
    z-index: 1;
}

.analysis-card .description {
    color: var(--color-text-light);
    margin-bottom: var(--spacing-md);
    line-height: 1.7;
    flex-grow: 1;
    position: relative;
    z-index: 1;
}

.read-more {
    display: inline-flex;
    align-items: center;
    color: var(--color-primary);
    font-weight: 600;
    font-size: 0.9375rem;
    transition: var(--transition);
    position: relative;
    z-index: 1;
    margin-top: auto;
}

.analysis-card-link:hover .read-more {
    transform: translateX(6px);
}

/* ========================================
   COMING SOON CARD
   ======================================== */

.coming-soon-wrapper {
    cursor: default;
    pointer-events: none;
}

.coming-soon-card {
    opacity: 0.55;
    border-style: dashed;
    border-color: var(--color-border);
}

.coming-soon-card::before {
    display: none;
}

.coming-soon-card::after {
    display: none;
}

.coming-soon-card .tag {
    background-color: rgba(107, 114, 128, 0.1);
    color: var(--color-text-light);
}

.coming-soon-card h3 {
    color: var(--color-text-light);
}

.coming-soon-label {
    color: var(--color-text-light);
    font-weight: 500;
    font-style: italic;
}

/* ========================================
   CONTENT PAGE
   ======================================== */

.content-page {
    background-color: var(--color-background);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-sm);
}

.page-header {
    margin-bottom: var(--spacing-2xl);
    padding-bottom: var(--spacing-lg);
    border-bottom: 2px solid var(--color-border-light);
}

.page-header h2 {
    font-size: 2.25rem;
    margin-bottom: var(--spacing-md);
}

.content-section {
    margin-bottom: var(--spacing-2xl);
}

.content-section h3 {
    color: var(--color-text);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-xs);
    border-bottom: 2px solid var(--color-border-light);
}

.info-box {
    background-color: var(--color-background-alt);
    border-left: 4px solid var(--color-primary);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-sm);
    margin-bottom: var(--spacing-md);
}

.info-box p {
    margin-bottom: 0;
}

.info-box p:last-child {
    margin-bottom: 0;
}

/* ========================================
   SKILLS & CONTACT GRIDS
   ======================================== */

.skills-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(280px, 1fr));
    gap: var(--spacing-lg);
    align-items: stretch;
}

.skill-item {
    background-color: var(--color-background-alt);
    padding: var(--spacing-lg);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    transition: var(--transition);
}

.skill-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-primary);
}

.skill-item h4 {
    color: var(--color-primary);
    margin-bottom: var(--spacing-xs);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-xl);
}

/* Contact grid is now handled by flip-card styles below */

/* ========================================
   ANALYSIS PAGE
   ======================================== */

.analysis-page {
    background-color: var(--color-background);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-2xl);
    box-shadow: var(--shadow-sm);
}

.analysis-header {
    margin-bottom: var(--spacing-2xl);
    padding-bottom: var(--spacing-xl);
    border-bottom: 2px solid var(--color-border-light);
}

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

.analysis-header h2 {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-sm);
    line-height: 1.2;
}

.analysis-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-light);
    margin-bottom: var(--spacing-md);
    line-height: 1.6;
}

.analysis-section {
    margin-bottom: var(--spacing-2xl);
}

.analysis-section h3 {
    color: var(--color-text);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-xs);
    border-bottom: 2px solid var(--color-border-light);
}

.analysis-section ul {
    margin-left: var(--spacing-lg);
    margin-bottom: var(--spacing-md);
}

.analysis-section li {
    margin-bottom: var(--spacing-sm);
    color: var(--color-text-light);
}

/* ========================================
   INSIGHTS LIST
   ======================================== */

.insights-list {
    list-style: none;
    margin-left: 0;
}

.insights-list > li {
    position: relative;
    padding-left: 2.5rem;
    padding-top: var(--spacing-sm);
    padding-bottom: var(--spacing-sm);
    padding-right: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
    background-color: var(--color-background-alt);
    border-left: 4px solid var(--color-primary);
    border-radius: var(--border-radius-sm);
}

.insights-list > li::before {
    content: '✓';
    position: absolute;
    left: 0.85rem;
    top: 1rem;
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-primary);
    color: white;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: bold;
}

/* ---------- INSIGHT CU CHART ---------- */

.insight-with-chart .insight-core {
    padding-left: 0;
}

.insight-core::before {
    content: none;
}

/* butonul de toggle */
.insight-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 999px;
    border: 1px solid var(--color-border);
    background-color: var(--color-background);
    color: var(--color-primary);
    cursor: pointer;
    transition: var(--transition);
    margin-top: var(--spacing-xs);
}

.insight-toggle:hover {
    background-color: var(--color-background-alt);
    border-color: var(--color-primary);
}

.insight-toggle .toggle-icon {
    font-size: 0.9rem;
    transition: transform 0.25s ease;
}

.insight-toggle[aria-expanded="true"] .toggle-icon {
    transform: rotate(180deg);
}

/* panoul cu chart */
.insight-chart-panel {
    padding-top: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transform-origin: top;
    transition:
        max-height 0.4s ease,
        opacity 0.3s ease,
        padding-top 0.3s ease;
}

.insight-chart-panel.is-open {
    max-height: 700px;
    opacity: 1;
    padding-top: var(--spacing-sm);
}

.insight-chart-panel img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-sm);
}

.next-steps {
    background-color: rgba(37, 99, 235, 0.05);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-sm);
    border-left: 3px solid var(--color-primary);
    margin-top: var(--spacing-md);
}

/* ========================================
   POWER BI EMBED
   ======================================== */

/* Wide section — breaks out of .analysis-page padding for full-width dashboard */
.analysis-section-wide {
    margin-left: calc(-1 * var(--spacing-2xl));
    margin-right: calc(-1 * var(--spacing-2xl));
    padding-left: var(--spacing-lg);
    padding-right: var(--spacing-lg);
}

@media (max-width: 768px) {
    .analysis-section-wide {
        margin-left: calc(-1 * var(--spacing-lg));
        margin-right: calc(-1 * var(--spacing-lg));
        padding-left: var(--spacing-sm);
        padding-right: var(--spacing-sm);
    }
}

@media (max-width: 480px) {
    .analysis-section-wide {
        margin-left: calc(-1 * var(--spacing-md));
        margin-right: calc(-1 * var(--spacing-md));
        padding-left: var(--spacing-xs);
        padding-right: var(--spacing-xs);
    }
}

.powerbi-embed {
    position: relative;
    width: 100%;
    background-color: var(--color-background-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-top: var(--spacing-lg);
    /* Tighter container to eliminate dead space below dashboard content */
    aspect-ratio: 1024 / 680;
}

.powerbi-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Tablet */
@media (max-width: 768px) {
    .powerbi-embed {
        aspect-ratio: auto;
        height: 700px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .powerbi-embed {
        aspect-ratio: auto;
        height: 550px;
    }
}

.embed-placeholder {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    width: 80%;
}

.embed-placeholder p:first-child {
    font-size: 2rem;
    margin-bottom: var(--spacing-sm);
}

.embed-note {
    color: var(--color-text-light);
    font-size: 0.875rem;
    line-height: 1.6;
}

/* ========================================
   ANALYSIS FOOTER
   ======================================== */

.analysis-footer {
    margin-top: var(--spacing-2xl);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-border);
}

.back-link {
    display: inline-flex;
    align-items: center;
    color: var(--color-text-light);
    font-weight: 500;
    transition: var(--transition);
}

.back-link:hover {
    color: var(--color-primary);
    transform: translateX(-4px);
}

/* ========================================
   FOOTER
   ======================================== */

footer {
    background-color: var(--color-background);
    border-top: 1px solid var(--color-border);
    padding: 0.6rem 0;
    text-align: center;
    margin-top: auto;
}

footer p {
    color: var(--color-text);
    font-size: 0.875rem;
    margin: 0;
}

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

@media (max-width: 768px) {
    :root {
        --spacing-xl: 2rem;
        --spacing-2xl: 2.5rem;
    }
    
    h1 {
        font-size: 1.75rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .hero h2 {
        font-size: 1.75rem;
    }
    
    .analysis-header h2 {
        font-size: 1.75rem;
    }
    
    .page-header h2 {
        font-size: 1.75rem;
    }
    
    .content-page,
    .analysis-page {
        padding: var(--spacing-lg);
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 var(--spacing-sm);
    }

    /* HEADER ULTRA-COMPACT PE MOBILE */
    header {
        padding: 0;
        height: 50px;
        display: flex;
        align-items: center;
    }
    
    header:hover {
        padding: 0;
        height: 50px;
    }
    
    .header-content {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        height: 100%;
        gap: var(--spacing-sm);
    }
    
    .brand {
        display: flex;
        align-items: center;
        height: 100%;
    }
    
    .brand-logo {
        height: 24px !important;
    }
    
    header:hover .brand-logo {
        height: 24px !important;
    }
    
    /* Motto ascuns complet pe mobile */
    .subtitle {
        display: none !important;
    }
    
    header:hover .subtitle {
        display: none !important;
    }
    
    .brand h1 {
        font-size: 1.125rem;
    }
    
    nav {
        display: flex;
        align-items: center;
        gap: 0.3rem;
        height: 100%;
    }
    
    nav a {
        font-size: 0.8125rem;
        padding: 0.35rem 0.5rem;
        height: fit-content;
    }
    
    main {
        padding: var(--spacing-lg) 0;
    }
    
    .content-page,
    .analysis-page {
        padding: var(--spacing-md);
    }
    
    .analysis-card {
        padding: var(--spacing-md);
    }
}

/* ========================================
    LANDSCAPE TWEAKS
   ======================================== */

@media (max-width: 900px) and (orientation: landscape) {
    header {
        padding: 0.5rem 0;
    }

    .header-content {
        flex-direction: row;
        align-items: center;
        gap: var(--spacing-md);
    }

    .brand h1 {
        font-size: 1.125rem;
    }

    .subtitle {
        display: none;
    }

    nav a {
        font-size: 0.875rem;
        padding: 0.25rem 0.75rem;
    }

    main {
        padding: var(--spacing-md) 0;
    }

    .powerbi-embed {
        padding-bottom: 0;
        height: 80vh;
        border-width: 1px;
    }

    .powerbi-embed iframe {
        height: 100%;
    }
}

/* ========================================
   UTILITIES
   ======================================== */

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

.mt-sm { margin-top: var(--spacing-sm); }
.mt-md { margin-top: var(--spacing-md); }
.mt-lg { margin-top: var(--spacing-lg); }
.mt-xl { margin-top: var(--spacing-xl); }

.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.mb-lg { margin-bottom: var(--spacing-lg); }
.mb-xl { margin-bottom: var(--spacing-xl); }

/* ========================================
   ANIMATIONS
   ======================================== */

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

.analysis-card,
.content-page,
.analysis-page {
    animation: fadeIn 0.5s ease-out;
}

/* ========================================
   CONTACT FLIP CARDS - 3D EFFECT
   ======================================== */

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-xl);
    perspective: 1000px;
}

/* Flip Card Container */
.flip-card {
    background-color: transparent;
    width: 100%;
    height: 320px;
    perspective: 1000px;
    cursor: pointer;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

/* Flip on hover (desktop) */
.flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
}

/* Flip on click/touch (mobile) */
.flip-card.flipped .flip-card-inner {
    transform: rotateY(180deg);
}

/* Front and Back faces */
.flip-card-front,
.flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: var(--spacing-lg) var(--spacing-xl);
    box-shadow: var(--shadow-md);
    transition: box-shadow 0.3s ease;
}

.flip-card:hover .flip-card-front,
.flip-card:hover .flip-card-back {
    box-shadow: var(--shadow-lg);
}

/* FRONT - Default view */
.flip-card-front {
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 2px solid var(--color-border);
}

.flip-card-front h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-xs);
    color: var(--color-text);
}

.contact-hint {
    font-size: 0.875rem;
    color: var(--color-text-light);
    font-style: italic;
    margin-top: var(--spacing-sm);
}

/* BACK - Revealed view */
.flip-card-back {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: white;
    transform: rotateY(180deg);
}

.flip-card-back h4 {
    font-size: 1.125rem;
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* SVG Icons */
.contact-icon-svg {
    width: 80px;
    height: 80px;
    margin-bottom: var(--spacing-lg);
    color: var(--color-primary);
    transition: transform 0.3s ease;
}

.contact-icon-svg.small {
    width: 48px;
    height: 48px;
    margin-bottom: var(--spacing-md);
    color: white;
}

.contact-icon-svg.linkedin {
    color: #0A66C2;
}

.contact-icon-svg.small.linkedin {
    color: white;
}

.flip-card:hover .contact-icon-svg:not(.small) {
    transform: scale(1.1) rotate(5deg);
}

.contact-icon-svg svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

/* Contact Link on back */
.contact-link {
    display: inline-block;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    padding: var(--spacing-sm) var(--spacing-lg);
    background-color: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90%;
}

.contact-link:hover {
    background-color: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .flip-card {
        height: 280px;
    }
    
    .contact-icon-svg {
        width: 64px;
        height: 64px;
    }
    
    .flip-card-front h3 {
        font-size: 1.25rem;
    }
    
    .contact-link {
        font-size: 0.85rem;
        padding: var(--spacing-xs) var(--spacing-md);
        max-width: 95%;
        white-space: nowrap;
    }
}

@media (max-width: 480px) {
    .flip-card {
        height: 260px;
    }
    
    .contact-link {
        font-size: 0.75rem;
        padding: 0.5rem 0.75rem;
        max-width: 100%;
    }
    
    .flip-card-back h4 {
        font-size: 1rem;
        margin: 0;
    }
}

/* Accessibility - reduce motion */
@media (prefers-reduced-motion: reduce) {
    .flip-card-inner {
        transition: none;
    }
    
    .flip-card:hover .flip-card-inner {
        transform: none;
    }
}

/* ========================================
   CLEAN MINIMAL CONTACT PAGE
   ======================================== */

/* Contact Main Styling */
.contact-main {
    position: relative;
    z-index: 1;
    padding: 0;
    flex: 1;
    display: flex;
}

.contact-main .container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
    display: flex;
    flex: 1;
}

.contact-content {
    background: transparent;
    backdrop-filter: none;
    border: none;
    border-radius: 0;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
    width: 100%;
    padding: var(--spacing-2xl);
}

/* Contact Header */
.contact-header {
    margin-bottom: var(--spacing-2xl);
}

/* Intro Box - Similar to Cards */
.contact-intro-box {
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    max-width: 100%;
}

.contact-intro-box:hover {
    box-shadow: var(--shadow-lg);
    border-color: rgba(37, 99, 235, 0.3);
}

/* Header Accent - Small Label Style */
.header-accent {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-md);
}

.accent-dot {
    width: 8px;
    height: 8px;
    background: var(--color-primary);
    border-radius: 50%;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.7;
    }
}

.accent-text {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-primary);
}

/* Intro Text */
.intro-text {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-text-light);
    margin: 0;
}

/* Cards Section */
.contact-cards-section {
    margin-top: var(--spacing-2xl);
    margin-bottom: var(--spacing-2xl);
}

/* Enhanced Flip Cards - Fade in animation (Contact only) */
.contact-main .flip-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.contact-main .flip-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.contact-main .flip-card:nth-child(2) {
    transition-delay: 0.1s;
}

/* Absolute Full Width Footer */
.contact-footer-absolute {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    margin-top: auto;
    padding: 0.6rem 0;
    border-top: 1px solid var(--color-border);
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
    text-align: center;
    background-color: var(--color-background);
}

.contact-footer-absolute p {
    color: var(--color-text);
    font-size: 0.875rem;
    margin: 0;
}

/* Remove all decorative elements */
.contact-background,
.floating-shapes,
.decorative-line,
.card-sparkles,
.contact-footer-decoration {
    display: none !important;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .intro-text {
        font-size: 1rem;
    }
    
    .contact-intro-box {
        padding: var(--spacing-lg);
    }

    .contact-content {
        padding: var(--spacing-lg);
    }
}

@media (max-width: 480px) {
    .intro-text {
        font-size: 0.9375rem;
        line-height: 1.7;
    }

    .accent-text {
        font-size: 0.8125rem;
    }

    .contact-content {
        padding: var(--spacing-md);
    }

    .contact-footer-absolute p {
        font-size: 0.8125rem;
    }
    
    /* About intro text - make smaller to fit on mobile */
    .about-lead {
        font-size: 1.125rem;
        line-height: 1.5;
    }
    
    /* FIX: Flip cards on mobile - prevent overflow */
    .flip-card {
        max-width: 100%;
    }
    
    .flip-card-inner {
        max-width: 100%;
    }
    
    .flip-card-back {
        padding: 1.25rem !important;
        font-size: 0.875rem;
    }
    
    .skill-bullets {
        padding-left: 0;
        padding-right: 0.5rem;
        font-size: 0.875rem;
        max-width: 100%;
        gap: 0.625rem;
    }
    
    .skill-bullets li {
        margin-bottom: 0;
        line-height: 1.4;
        font-size: 0.875rem;
    }
    
    /* SQL card has more content - reduce size slightly */
    .skill-flip[data-skill="sql"] .flip-card-back {
        padding: 1rem !important;
    }
    
    .skill-flip[data-skill="sql"] .skill-bullets {
        gap: 0.5rem;
        font-size: 0.8125rem;
    }
    
    .skill-flip[data-skill="sql"] .skill-bullets li {
        font-size: 0.8125rem;
        line-height: 1.35;
    }
    
    .skill-back-head {
        margin-bottom: 0.875rem;
    }
    
    .skill-back-head h4 {
        font-size: 1rem;
        margin-top: 0.25rem;
    }
    
    /* Reduce logo sizes on mobile back */
    .skill-logo.small {
        width: 36px;
        height: 36px;
    }
    
    .skill-icon-badge {
        margin-bottom: 0.5rem;
    }
}

/* ========================================
   MODERN ABOUT PAGE
   ======================================== */

.about-page {
    /* Match Home page width feel */
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: var(--spacing-2xl);
    overflow-x: hidden;

    background: transparent;
    backdrop-filter: none;

    border: none;
    border-radius: 0;
    box-shadow: none;
}

.about-intro {
    margin-bottom: var(--spacing-xl);
}

.about-lead {
    margin: 0;
    font-size: 1.6rem;
    line-height: 1.6;
    color: var(--color-text-light);
}

.about-rule {
    height: 1px;
    width: 100%;
    background: var(--color-border);
    margin-bottom: var(--spacing-2xl);
}

.about-heading {
    margin: 0 0 var(--spacing-md) 0;
    font-size: 1.5rem;
    line-height: 1.3;
    font-weight: 700;
    color: var(--color-text);
}

/* About section labels: black (Contact keeps the blue accent) */
.about-page .accent-text {
    color: var(--color-text);
}

.about-page .accent-dot {
    background: var(--color-text);
}

.about-section {
    margin-bottom: var(--spacing-2xl);
}

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

/* Section Label (like Contact's accent) */
.section-label {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-lg);
}

/* Modern Info Boxes */
.info-box-modern {
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    transition: all 0.3s ease;
}

.info-box-modern:hover {
    box-shadow: var(--shadow-md);
    border-color: rgba(37, 99, 235, 0.3);
}

.info-box-modern:last-child {
    margin-bottom: 0;
}

.info-box-modern p {
    margin: 0;
    line-height: 1.8;
    color: var(--color-text);
}


/* Project focus: TL;DR + Accordion (scannable) */
.tldr-card{
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-md);
    margin-bottom: var(--spacing-lg);
}

.tldr-card h3{
    margin: 0 0 var(--spacing-sm);
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: rgba(17, 24, 39, 0.65);
}

.tldr-card ul{
    margin: 0;
    padding-left: 1.1rem;
    color: rgba(17, 24, 39, 0.85);
    line-height: 1.65;
}

.tldr-card li{
    margin: 0.25rem 0;
}

.accordion{
    display: grid;
    gap: var(--spacing-md);
}

.acc-item{
    background: #fff;
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.acc-item summary{
    cursor: pointer;
    padding: var(--spacing-lg);
    font-weight: 700;
    color: var(--color-text);
    list-style: none;
    position: relative;
    padding-right: 3.25rem;
}

.acc-item summary::-webkit-details-marker{
    display: none;
}

.acc-item summary::after{
    content: "+";
    position: absolute;
    right: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    width: 2rem;
    height: 2rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    background: rgba(17, 24, 39, 0.06);
    color: rgba(17, 24, 39, 0.75);
    font-weight: 800;
}

.acc-item[open] summary::after{
    content: "–";
}

.acc-item p{
    margin: 0;
    padding: 0 var(--spacing-lg) var(--spacing-lg);
    color: rgba(17, 24, 39, 0.82);
    line-height: 1.75;
}

/* Skills Flip Grid */
.skills-flip-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--spacing-xl);
    perspective: 1000px;
}

/* Skill cards (About) - logos + per-skill themes */
.skill-flip {
    /* override default flip-card height for bullets */
    height: 340px;

    /* default theme vars (overwritten per skill) */
    --skill-border: rgba(37, 99, 235, 0.18);
    --skill-back-1: var(--color-primary);
    --skill-back-2: var(--color-primary-dark);
}

/* Per-skill themes */
.skill-flip[data-skill="sql"] {
    --skill-border: rgba(14, 116, 144, 0.22);
    --skill-back-1: #06b6d4;
    --skill-back-2: #0e7490;
}

.skill-flip[data-skill="excel"] {
    --skill-border: rgba(33, 115, 70, 0.22);
    --skill-back-1: #217346;
    --skill-back-2: #14532d;
}

.skill-flip[data-skill="powerbi"] {
    --skill-border: rgba(234, 179, 8, 0.25);
    --skill-back-1: #f59e0b;
    --skill-back-2: #b45309;
}

.skill-flip[data-skill="python"] {
    --skill-border: rgba(55, 118, 171, 0.22);
    --skill-back-1: #3776AB;
    --skill-back-2: #1e3a8a;
}

/* Front override */
.skill-flip .flip-card-front {
    border: 2px solid var(--skill-border);
}

/* Back override */
.skill-flip .flip-card-back {
    background: linear-gradient(135deg, var(--skill-back-1) 0%, var(--skill-back-2) 100%);
}

/* Logo images */
.skill-logo {
    width: 86px;
    height: 86px;
    object-fit: contain;
    margin-bottom: var(--spacing-md);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.12));
    transition: transform 0.3s ease;
}

.skill-logo.small {
    width: 44px;
    height: 44px;
    margin-bottom: 0;
    filter: none;
}

.skill-flip:hover .skill-logo:not(.small) {
    transform: scale(1.08) rotate(4deg);
}

.skill-tagline {
    margin: 0;
    margin-top: 0.25rem;
    font-size: 0.9rem;
    color: var(--color-text-light);
    font-style: italic;
}

/* Back head */
.skill-back-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
}

.skill-icon-badge {
    width: 58px;
    height: 58px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.35);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
}

/* Bullets on back */
.skill-bullets {
    list-style: none;
    padding: 0;
    margin: 0;
    max-width: 92%;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    text-align: left;
}

.skill-bullets li {
    display: flex;
    gap: 0.55rem;
    align-items: flex-start;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.94rem;
    line-height: 1.35;
}

.skill-bullets li::before {
    content: "•";
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.1;
}

/* Mobile Optimization */
@media (max-width: 768px) {
    .about-page {
        padding: var(--spacing-md);
        overflow-x: hidden;
    }
    
    .skills-flip-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
        padding: 0;
        margin-top: var(--spacing-lg);
    }
    
    .info-box-modern {
        padding: var(--spacing-md);
    }
    
    .flip-card {
        margin: 0;
        width: 100%;
    }
    
    .about-section {
        margin-bottom: var(--spacing-xl);
    }
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {
    header,
    footer,
    nav,
    .back-link,
    .read-more {
        display: none;
    }
    
    body {
        background-color: white;
    }
    
    .content-page,
    .analysis-page {
        border: none;
        box-shadow: none;
        padding: 0;
    }
    
    a {
        color: var(--color-text);
        text-decoration: underline;
    }
}

/* About skills responsive */
@media (max-width: 900px) {
    .skills-flip-grid {
        grid-template-columns: 1fr;
    }
}
