html {
    background: whitesmoke;
    padding: 2%;
    font-family: "Segoe UI", sans-serif;
    
}

:root {
    --fg: gold;
    --bg: navy;
}

body {
    border: 4px solid var(--bg);
    border-radius: 20px;
    padding: 20px;
    background-image: linear-gradient(rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.85)), url("My official picture.jpg");
    background-position: right;
    background-repeat: no-repeat;
    background-size: cover;
}

/* ----------------------------- Header ----------------------------- */
header {
    color: var(--bg);
    text-align: center;
    height: 200px;
    overflow: hidden;
    justify-content: center;
}

header h1 {
    font-size: 3rem;
    letter-spacing: 2px;
    text-shadow: 2px 2px 5px grey;
}

header p {
    color: var(--fg);
    font-size:1.4rem;
}

header div a {
    text-decoration: none;
}

/* ----------------------------- Typography ----------------------------- */
h2 {
    color: var(--bg);
    text-decoration: underline;
    font-size:2.3rem;
}

p {
    font-size: 1.1rem;
}



/* ----------------------------- Lists ----------------------------- */
#skills li:nth-child(even) {
    font-weight: bold;
    text-decoration: line-through;
}

#skills ul {
    list-style-type: square;
}

#contact ul {
    list-style-type: square;
}

#contact a {
    text-decoration: none;
    color: var(--bg);
}

#contact a:hover {
    color: var(--fg);
    font-size: 1.2rem;
}

#contact a:active {
    color: purple;
}

/* ----------------------------- Sections ----------------------------- */
#intro,
#skills,
#goals,
#contact {
    margin-bottom: 40px;
}

hr {
    border: 3px dotted var(--bg);
}

footer p::first-letter {
    font-size: 2rem;
}

/* ----------------------------- Form Styling ----------------------------- */
form {
    width: 100%;
    margin: 40px auto;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    padding: 25px auto;
    font-family: 'Courier New', Courier, monospace;
}

fieldset {
    padding: 20px;
    border: 3px solid var(--fg);
}

legend {
    font-size: 1.4em;
    font-weight: bold;
    color: var(--bg);
}

label {
    font-weight: 600;
}

button {
    border-style: none;
    height: 50px;
    color: var(--bg);
    font-weight: 600;
    background-color: gold;
    border-radius: 20px;
    transition: 1s;
    cursor: pointer;
}

button:hover {
    background-color: var(--bg);
    color: goldenrod;
}

/* Unified input look */
.h,
#telephone,
#things,
#file,
#age,
select {
    border-style: none;
    border-radius: 12px;
    transition: 1s;
}

/* Unified hover animation for inputs */
.h:hover,
#telephone:hover,
#things:hover,
#file:hover,
#age:hover,
select:hover {
    transform: translateX(10%);
    cursor: pointer;
    width: 50%;
    background-color: var(--fg);
    color: var(--bg);
}

#file,
#age {
    background-color: var(--bg);
    color: var(--fg);
}

select {
    width: 20%;
}

/* ----------------------------- Navbar ----------------------------- */
.navbar {
    overflow: hidden;
    background-color: var(--bg);
    width: 100%;
    height: 50px;
    line-height: 40px;
    position: sticky;
    top: 0;
    border-radius: 20px;
}

.navbar ul {
    float: left;
    list-style: none;
    padding: 0;
    margin: 0;
}

.navbar ul li {
    float: left;
    margin-right: 20px;
}

.navbar ul li:nth-child(1) {
    margin-left: 20px;
}

.navbar a {
    float: right;
    margin-right: 20px;
    color: var(--fg);
    text-decoration: none;
    transition: 1s;
}

.navbar a:hover {
    font-size: larger;
    color: goldenrod;
    font-weight: 600;
}

/* ----------------------------- Cards ----------------------------- */
.card-holder {
    display: flex;
    
    justify-content: space-between;
    margin-top: 20px;
}

.card {
    background-color: var(--bg);
    color: var(--fg);
    border-radius: 15px;
    padding: 20px;
    width: 250px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: transform 0.4s, box-shadow 0.4s, background-color 0.4s;
}

.card:hover {
    transform: translateY(-8px);
    background-color: var(--fg);
    color: var(--bg);
    box-shadow: 0 8px 16px rgba(0,0,0,0.3);
    cursor: pointer;
}

.card img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: block;
    margin: 0 auto;
}

.card:hover img {
    transform: scale(1.1);
    border-color: var(--bg);
    margin-bottom: 20px;
}


main{
    display: grid;
    grid-template-columns: repeat(3,1fr);
    grid:40px;
    

    grid-template-rows:1fr 1fr ;

    margin:10px auto;   
   
   
}

/* --------------------------------Mobile design----------------------*/


@media(max-width:1024px){


main{
    display: grid;
    grid-template-columns: 1fr;
    margin:10px auto;   
   
   
}

.card-holder {
    display: flex;
    gap:50px;
    flex-direction: column;
    margin-top: 20px;
    align-items: center;
}

}


@media(max-width:850px){


main{
    display: grid;
    grid-template-columns: 1fr;
    margin:10px auto;   
   
   
}

.card-holder {
    display: flex;
    gap:50px;
    flex-direction: column;
    margin-top: 20px;
    align-items: center;
}

}






