* {
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #f0f4f8;
    color: #333;
    transition: background-color 0.3s, color 0.3s;
}

body.dark-mode {
    background-color: #18232f;
    color: #ecf0f1;
}

body.dark-mode :link {
    color: #af55ff;
}

body.dark-mode :visited {
    color: #ce9cff;
}

body.dark-mode :link:active, :visited:active {
    color: #7910d3;
}

.container {
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

body.dark-mode .container {
    background: #34495e;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

h1 {
    margin: 0;
    font-size: 2.5em;
    color: #2c3e50;
}

body.dark-mode h1 {
    color: #ecf0f1;
}

.title {
    font-weight: 400;
    font-size: 1.2em;
    color: #7f8c8d;
}

body.dark-mode .title {
    color: #bdc3c7;
}

h2 {
    color: #2980b9;
    border-bottom: 2px solid #2980b9;
    padding-bottom: 5px;
    margin-bottom: 15px;
}

body.dark-mode h2 {
    color: #1abc9c;
    border-color: #1abc9c;
}

.experience-item, .education-item {
    margin-bottom: 20px;
    padding: 15px;
    border-left: 4px solid #2980b9;
    background: #ecf0f1;
    border-radius: 5px;
    transition: background 0.3s, transform 0.3s;
}

body.dark-mode .experience-item,
body.dark-mode .education-item {
    background: #2c3e50;
    border-left: 4px solid #1abc9c;
}

.experience-item:hover, .education-item:hover {
    background: #dfe6e9;
    transform: translateX(5px);
}

body.dark-mode .experience-item:hover,
body.dark-mode .education-item:hover {
    background: #233140;
}

.date {
    font-style: italic;
    color: #7f8c8d;
}

body.dark-mode .date {
    color: #bdc3c7;
}

.skills-list {
    list-style-type: none;
    padding: 0;
}

.skills-list li {
    background: #2980b9;
    color: white;
    padding: 10px;
    margin: 5px 0;
    border-radius: 5px;
    transition: background 0.3s;
}

.skills-list li:hover {
    background: #3498db;
}

body.dark-mode .skills-list li {
    background: #1abc9c;
}

footer {
    text-align: center;
    margin-top: 30px;
    font-size: 0.9em;
    color: #7f8c8d;
}

body.dark-mode footer {
    color: #bdc3c7;
}

.toggle-button {
    background-color: #2980b9;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.toggle-button:hover {
    background-color: #3498db;
}

body.dark-mode .toggle-button {
    background-color: #1abc9c;
}

body.dark-mode .toggle-button:hover {
    background-color: #16a085;
}

body.dark-mode .header {
    background-color: #1e1e1e;
}

body.dark-mode .skills-list li:hover {
    background: #3498db;
}

.toggle-container {
    display: flex;
    align-items: center;
    justify-content: right;
    margin-right: 10px;
    margin-top: 10px;
}

.toggle-checkbox {
    display: none;
}

.toggle-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    position: relative;
    width: 60px;
    height: 30px;
    background-color: #ccc;
    border-radius: 30px;
    transition: background-color 0.3s ease;
}

.toggle-icon {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    transition: opacity 0.3s ease;
}

.toggle-icon-sun {
    left: 5px;
    opacity: 0;
}

.toggle-icon-moon {
    right: 5px;
    opacity: 1;
}

.toggle-switch {
    position: absolute;
    top: 50%;
    left: 5px;
    width: 20px;
    height: 20px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.3s ease;
    transform: translateY(-50%);
}

.toggle-checkbox:checked + .toggle-label {
    background-color: #4caf50;
}

.toggle-checkbox:checked + .toggle-label .toggle-switch {
    transform: translate(30px, -50%);
}

.toggle-checkbox:checked + .toggle-label .toggle-icon-sun {
    opacity: 1;
}

.toggle-checkbox:checked + .toggle-label .toggle-icon-moon {
    opacity: 0;
}