/* AI Career Explorer Website Styling */

/* These variables store the main colors and design choices so they can be reused easily */
:root {
    --bg-main: #fbf9f6;
    --card-bg: rgba(255, 255, 255, 0.88);
    --border-soft: #eae5dd;
    --border-hover: #d8d0c3;

    --text-primary: #2c322e;
    --text-muted: #6e7771;

    --pastel-sage: #a3b899;
    --pastel-sage-bg: #f1f5ef;
    --pastel-sage-txt: #3b5032;

    --pastel-powder: #b2c9d3;
    --pastel-powder-bg: #f0f6f8;

    --pastel-lavender: #c8c2db;
    --pastel-lavender-bg: #f4f2f8;
    --pastel-lavender-txt: #4f4763;

    --pastel-peach: #eabfb9;
    --pastel-peach-bg: #fcf3f2;
    --pastel-peach-txt: #7d4842;

    /* Used for making rounded corners consistent throughout the page */
    --radius-lg: 24px;
    --radius-md: 14px;
    --radius-sm: 8px;

    /* Adds a soft shadow effect to cards */
    --shadow-soft: 0 10px 30px rgba(70, 75, 72, 0.04);
}


/* Removes default browser spacing so the design looks consistent */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


/* Allows smooth scrolling when clicking navigation links */
html {
    scroll-behavior: smooth;
}


/* Controls the overall page font, colors, spacing, and background */
body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.6;
    padding: 3rem 1.25rem 4rem;
    -webkit-font-smoothing: antialiased;
}


/* Uses a different font style for important headings */
h1, h2, h3 {
    font-family: 'Fraunces', Georgia, serif;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}


/* Keeps the website content centered and prevents it from becoming too wide */
.main-container {
    max-width: 920px;
    margin: 0 auto;
}


/* Creates the reusable card style used for each major section */
.section-card {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    padding: 2.75rem 2.25rem;
    margin-top: 2.25rem;
    box-shadow: var(--shadow-soft);
    transition: border-color 0.25s ease;
}


/* Adds a small visual change when the user hovers over a section */
.section-card:hover {
    border-color: var(--border-hover);
}


/* Controls spacing for section titles and descriptions */
.section-header {
    margin-bottom: 1.75rem;
}


.section-header h2 {
    font-size: 2rem;
    margin-bottom: 0.35rem;
}


.section-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
}


/* Hero section at the top of the website */
.hero-section {
    background: var(--card-bg);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    padding: 3.5rem 2.5rem 2.5rem;
    text-align: center;
    box-shadow: var(--shadow-soft);
}


.hero-title {
    font-size: 3.5rem;
    line-height: 1.05;
    margin-bottom: 0.25rem;
}


.hero-subtitle {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 1.35rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 1.5rem;
}


/* Navigation links at the top of the page */
.pill-navbar {
    margin-bottom: 2rem;
}


.nav-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    list-style: none;
    gap: 1.5rem;
}


.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}


.nav-links a:hover {
    color: var(--text-primary);
}
/* Buttons and quick actions inside the hero section */
.hero-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}


/* Creates the small information cards showing website statistics */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    border-top: 1px solid var(--border-soft);
    padding-top: 2rem;
}


.stat-card {
    background: var(--pastel-powder-bg);
    padding: 1.25rem 1rem;
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    align-items: center;
}


.stat-number {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 1.75rem;
    color: var(--text-primary);
}


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


/* Layout for the AI career information cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}


.career-card {
    background: #ffffff;
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}


/* Gives the cards a small lift effect when hovered */
.career-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.05);
}


.card-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}


.career-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}


.career-card p {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}


/* Displays the small skill labels under each career card */
.skills-tag-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}


.skill-tag {
    background: var(--pastel-lavender-bg);
    color: var(--pastel-lavender-txt);
    font-size: 0.75rem;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-weight: 500;
}


/* Allows tables to scroll horizontally on smaller screens */
.table-responsive {
    overflow-x: auto;
}


/* Main styling for all tables used in the project */
.pastel-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}


.pastel-table caption {
    caption-side: top;
    text-align: left;
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}


/* Adds spacing and borders to table cells */
.pastel-table th,
.pastel-table td {
    padding: 0.95rem 1rem;
    border-bottom: 1px solid var(--border-soft);
}


/* Styles the table headings differently from the data rows */
.pastel-table thead th {
    background-color: var(--pastel-powder-bg);
    color: var(--text-primary);
    font-weight: 600;
}


.pastel-table tbody tr {
    transition: background-color 0.2s ease;
}


.pastel-table tbody tr:hover {
    background-color: #faf7f2;
}


/* Formats the note section at the bottom of tables */
.pastel-table tfoot td {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-style: italic;
    text-align: center;
    padding-top: 1.25rem;
    border-bottom: none;
}


/* Used for the roadmap table that has merged cells */
.complex-grid th,
.complex-grid td {
    border: 1px solid var(--border-soft);
    text-align: center;
}


/* Tic Tac Toe style grid created using an HTML table */
.tictactoe-flex {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    flex-wrap: wrap;
}


.ttt-board {
    border-collapse: collapse;
    background: #ffffff;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
}


.ttt-board caption {
    display: none;
}


.ttt-board td {
    width: 70px;
    height: 70px;
    border: 2px solid var(--border-soft);
    text-align: center;
    vertical-align: middle;
    font-size: 1.8rem;
}


/* Description box beside the Tic Tac Toe table */
.challenge-summary-card {
    background-color: var(--pastel-sage-bg);
    border: 1px solid var(--pastel-sage);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    max-width: 300px;
}


.challenge-summary-card h3 {
    font-size: 1.25rem;
    color: var(--pastel-sage-txt);
    margin-bottom: 0.4rem;
}


.winner-text {
    font-size: 0.9rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}


.challenge-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
}
/* Form section styling */
fieldset {
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    background: #ffffff;
}


/* Styles the title labels for each form group */
legend {
    padding: 0 0.5rem;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--pastel-sage-txt);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}


/* Organizes form inputs into a responsive grid */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.25rem;
}


.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}


/* Makes certain form items take up the full row */
.input-group.full-span {
    grid-column: 1 / -1;
}


.space-top {
    margin-top: 1.25rem;
}


.space-bottom {
    margin-bottom: 1.25rem;
}


label,
.group-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
}


/* Gives all text-based form inputs the same appearance */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="time"],
input[type="month"],
input[type="week"],
input[type="datetime-local"],
input[type="search"],
input[type="url"],
select,
textarea {
    width: 100%;
    padding: 0.75rem 0.95rem;
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.9rem;
    background-color: #faf8f5;
    color: var(--text-primary);
    transition: border-color 0.2s ease;
}


/* Changes the input style when the user clicks inside a field */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--pastel-sage);
    background-color: #ffffff;
}


/* Styles the confidence level slider input */
input[type="range"] {
    accent-color: var(--pastel-sage);
    cursor: pointer;
}


/* Controls the layout of radio buttons and checkboxes */
.options-flex {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    margin-top: 0.4rem;
}


.options-flex label {
    font-size: 0.85rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
}


/* Places the submit and reset buttons next to each other */
.button-row {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}


/* General button styling used throughout the website */
.btn {
    padding: 0.8rem 1.6rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.2s ease;
}


.btn-primary {
    background-color: var(--pastel-sage);
    color: var(--pastel-sage-txt);
}


.btn-primary:hover {
    background-color: #92a888;
}


.btn-secondary {
    background-color: var(--pastel-powder-bg);
    color: var(--text-primary);
}


.btn-secondary:hover {
    background-color: #e2ebf0;
}


/* Back to top button at the bottom of the page */
.back-top-wrapper {
    margin-top: 3.5rem;
    text-align: center;
}


.back-top-link {
    display: inline-block;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.88rem;
    font-weight: 500;
    padding: 0.65rem 1.4rem;
    border-radius: 30px;
    border: 1px solid var(--border-soft);
    background-color: var(--card-bg);
    transition: all 0.2s ease;
}


.back-top-link:hover {
    color: var(--text-primary);
    border-color: var(--border-hover);
}


/* Adjusts the layout for phones and smaller screens */
@media (max-width: 600px) {

    .hero-section {
        padding: 2.5rem 1.25rem 1.5rem;
    }


    .hero-title {
        font-size: 2.6rem;
    }


    .nav-links {
        gap: 1rem;
        font-size: 0.85rem;
    }


    /* Stacks buttons vertically on smaller screens */
    .hero-actions {
        flex-direction: column;
    }


    .button-row {
        flex-direction: column;
    }


    .btn {
        width: 100%;
        text-align: center;
    }
}