/* =============================================================
   cantyland.net — Modern Resume Portfolio Styles
   ============================================================= */

:root {
    --accent: #00cc66;
    --accent-dark: #00a854;
    --bg-body: #1a1a2e;
    --bg-sidebar: #16213e;
    --bg-card: #1e2a47;
    --bg-skill-track: #2a2a4a;
    --text-primary: #ffffff;
    --text-muted: #a0a0b8;
    --text-dark: #c0c0d0;
    --highlight-bg: var(--accent);
    --highlight-text: #fff;
    --shadow: rgba(0, 0, 0, 0.3);
}

html { scroll-behavior: smooth; }

body {
    background-color: var(--bg-body) !important;
    color: var(--text-primary) !important;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    overflow-x: hidden;
}

/* ---- Light mode overrides ---- */
body.light-mode {
    --bg-body: #f0f2f5;
    --bg-sidebar: #ffffff;
    --bg-card: #ffffff;
    --bg-skill-track: #e0e0e0;
    --text-primary: #1a1a2e;
    --text-muted: #555;
    --text-dark: #333;
    --shadow: rgba(0, 0, 0, 0.1);
}
body.light-mode { background-color: var(--bg-body) !important; color: var(--text-primary) !important; }
body.light-mode .navbar { background-color: #fff !important; box-shadow: 0 2px 8px var(--shadow); }
body.light-mode .navbar .navbar-brand,
body.light-mode .navbar .nav-link { color: #1a1a2e !important; }
body.light-mode .card { background-color: var(--bg-card) !important; border: 1px solid #ddd; }
body.light-mode .sidebar { background-color: var(--bg-sidebar) !important; box-shadow: 2px 0 12px var(--shadow); }
body.light-mode .card-title { color: var(--text-primary) !important; }
body.light-mode hr { border-color: #ccc; }
body.light-mode footer { background-color: #e9ecef; }

/* =============================================================
   PORTFOLIO LAYOUT — sidebar + main
   ============================================================= */

.portfolio-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    min-height: calc(100vh - 56px);
    gap: 0;
}

/* ---- SIDEBAR ---- */
.sidebar {
    background: var(--bg-sidebar);
    padding: 2.5rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: sticky;
    top: 56px;
    height: calc(100vh - 56px);
    overflow-y: auto;
    border-right: 1px solid rgba(255,255,255,0.06);
}

.profile-initials {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 1.2rem;
    box-shadow: 0 4px 20px rgba(0, 204, 102, 0.3);
}

.social-icons {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.social-icons a {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-2px);
}

.sidebar-label {
    font-size: 0.7rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
}

.sidebar-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.sidebar-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    width: 100%;
}

.sidebar-buttons .btn {
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.55rem 1rem;
}

.btn-accent {
    background: var(--accent) !important;
    border-color: var(--accent) !important;
    color: #fff !important;
}

.btn-accent:hover {
    background: var(--accent-dark) !important;
    border-color: var(--accent-dark) !important;
}

.btn-outline-accent {
    border: 2px solid var(--accent) !important;
    color: var(--accent) !important;
    background: transparent !important;
}

.btn-outline-accent:hover {
    background: var(--accent) !important;
    color: #fff !important;
}

/* ---- MAIN CONTENT ---- */
.main-content {
    padding: 2.5rem 3rem;
    overflow-y: auto;
}

/* ---- HERO ---- */
.hero-section {
    margin-bottom: 3rem;
}

.hero-greeting {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 0.8rem;
}

.hero-greeting .accent-name {
    color: var(--accent);
    font-weight: 600;
}

.hero-headline {
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.2rem;
    color: var(--text-primary);
}

.highlight {
    background: var(--accent);
    color: #fff;
    padding: 0.1em 0.4em;
    border-radius: 6px;
    display: inline;
}

.hero-desc {
    font-size: 1rem;
    color: var(--text-muted);
    max-width: 600px;
    line-height: 1.7;
}

/* ---- TYPING EFFECT ---- */
#typed-subtitle {
    color: var(--accent);
    font-weight: 600;
}

.typing-cursor {
    display: inline-block;
    width: 2px;
    height: 1.1em;
    background-color: var(--accent);
    margin-left: 2px;
    vertical-align: text-bottom;
    animation: blink 0.7s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ---- STATS ROW ---- */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
    padding: 1.5rem 0;
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

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

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
}

.stat-number .accent-plus {
    color: var(--accent);
}

.stat-line1 {
    display: block;
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 600;
    margin-top: 0.3rem;
}

.stat-line2 {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ---- SKILLS SECTION ---- */
.skills-section {
    margin-bottom: 3rem;
}

.skills-section h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.section-label {
    font-size: 0.7rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-label::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
    display: inline-block;
}

.skills-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
}

.skill-item {
    margin-bottom: 0.2rem;
}

.skill-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
    color: var(--text-dark);
}

.skill-track {
    height: 8px;
    background: var(--bg-skill-track);
    border-radius: 4px;
    overflow: hidden;
}

.skill-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent), var(--accent-dark));
    border-radius: 4px;
    transition: width 1.2s ease;
}

/* ---- CONTENT SECTIONS (Projects, Resume, Contact) ---- */
.content-section {
    margin-bottom: 3rem;
}

.content-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

/* ---- PROJECT CARDS ---- */
.project-card {
    background: var(--bg-card) !important;
    border: 1px solid rgba(255,255,255,0.06) !important;
    border-radius: 12px !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 24px rgba(0, 204, 102, 0.15);
}

/* ---- TIMELINE ---- */
.timeline-item {
    border-left: 3px solid var(--accent);
    padding-left: 1.5rem;
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -7px;
    top: 6px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid var(--bg-body);
}

/* ---- CONTACT BUTTONS ---- */
.contact-btn {
    transition: all 0.3s ease;
}

.contact-btn:hover {
    box-shadow: 0 0 15px rgba(0, 204, 102, 0.3);
    transform: translateY(-2px);
}

/* ---- THEME TOGGLE ---- */
#theme-toggle {
    cursor: pointer;
    font-size: 1.2rem;
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: #fff;
}

#theme-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(30deg);
}

body.light-mode #theme-toggle {
    color: #212529;
    border-color: rgba(0, 0, 0, 0.2);
}

/* ---- FADE IN ANIMATION (CSS-only, triggered by JS class) ---- */
.fade-in-section {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in-section.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---- RESPONSIVE ---- */
@media (max-width: 992px) {
    .portfolio-layout {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: relative;
        top: 0;
        height: auto;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        padding: 1.5rem;
        gap: 1rem;
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .profile-initials { width: 80px; height: 80px; font-size: 1.8rem; margin-bottom: 0; }
    .sidebar-buttons { flex-direction: row; width: auto; }
    .main-content { padding: 1.5rem; }
    .hero-headline { font-size: 2rem; }
    .skills-grid { grid-template-columns: 1fr; }
    .stats-row { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
}

@media (max-width: 576px) {
    .hero-headline { font-size: 1.6rem; }
    .stat-number { font-size: 1.8rem; }
    .stats-row { grid-template-columns: 1fr; }
    .sidebar { flex-direction: column; }
    .sidebar-buttons { flex-direction: column; width: 100%; }
}
