:root {
    --primary: #38b6ff;
    --primary-dark: #1a97e0;
    --dark: rgb(2, 6, 23);
    --dark-light: rgb(10, 15, 35);
    --text: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent; /* Elimina flash al tocar en móviles */
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--dark);
    color: var(--text);
    overflow-x: hidden;
    line-height: 1.6;
}

button, 
input, 
select, 
textarea {
    font-family: inherit; /* Consistencia en fuentes de formularios */
}

/* Scrollbar personalizada */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--dark);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Contenedor principal */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Header y Navegación */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    background: rgba(2, 6, 23, 0.8);
}

header.scrolled {
    padding: 1rem 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem; /* Add some gap between elements */
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
}

.logo span {
    color: var(--primary);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
    padding: 0.5rem 0;
}

.nav-links a::after {
    display: none; /* Esto elimina completamente la línea */
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
    text-shadow: 0 0 8px rgba(56, 182, 255, 0.5);
}

.header-right-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-right-controls .separator {
    color: var(--text-secondary);
    font-size: 1.2rem;
    margin: 0 0.5rem;
}

.header-right-controls .social-links {
    display: flex;
    gap: 1rem;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-links a {
    color: var(--text);
    font-size: 1.2rem;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--primary);
    transform: translateY(-3px);
}

.menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}

/* Theme and Language Toggle Buttons */
.theme-toggle, .lang-toggle {
    margin-left: 1.5rem;
}

.btn-icon {
    background: none;
    border: none;
    color: var(--text);
    font-size: 1.2rem;
    cursor: pointer;
    transition: var(--transition);
    padding: 0.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    color: var(--primary);
    background-color: var(--dark-light);
}

/* Hide one icon based on theme */
body.light-mode .theme-toggle .fa-sun {
    display: none;
}

body.light-mode .theme-toggle .fa-moon {
    display: inline-block;
}

body.dark-mode .theme-toggle .fa-sun {
    display: inline-block;
}

body.dark-mode .theme-toggle .fa-moon {
    display: none;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(56, 182, 255, 0.1), transparent 40%);
    z-index: -1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    max-width: 600px;
}

.hero-greeting {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--primary);
    margin-bottom: 1rem;
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
    animation-delay: 0.2s;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    line-height: 1.2;
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
    animation-delay: 0.4s;
}

.hero-title span {
    color: var(--primary);
    position: relative;
}

.hero-title span::after {
    content: none !important;
    display: none !important;
}

.hero-title .cursor {
    display: inline-block;
    margin-left: 3px;
    width: 3px;
    height: 1.2em;
    background-color: var(--primary);
    animation: blink 1s step-end infinite;
    color: transparent;
    vertical-align: middle;
    position: relative;
    top: -2px;
}

.hero-description {
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    color: var(--text-secondary);
    margin-bottom: 2rem;
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
    animation-delay: 0.6s;
}

.hero-image {
    position: relative;
    text-align: center;
}

.hero-image::before {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(56, 182, 255, 0.2), transparent 70%);
    z-index: -1;
    border-radius: 50%;
    animation: pulse 4s infinite ease-in-out;
}

.profile-img {
    width: 350px;
    height: 350px;
    border-radius: 50%;
    object-fit: cover;
    object-position: 50% 20%; /* Ajusta el enfoque vertical de la imagen */
    border: 4px solid var(--primary);
    box-shadow: 0 0 30px rgba(56, 182, 255, 0.5);
    opacity: 0;
    animation: fadeIn 0.8s ease forwards, float 5s ease-in-out infinite;
    animation-delay: 0.8s;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(56, 182, 255, 0.4);
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
    animation-delay: 0.8s;
}

.btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(56, 182, 255, 0.6);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
    margin-left: 1rem;
    box-shadow: none;
}

.btn-outline:hover {
    background-color: var(--primary);
    color: white;
}

.hero-social {
    display: flex;
    gap: 1.5rem;
    margin-top: 2rem;
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
    animation-delay: 1s;
}

.social-icon {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: var(--dark-light);
    color: var(--text);
    font-size: 1.2rem;
    transition: var(--transition);
}

.social-icon:hover {
    background-color: var(--primary);
    transform: translateY(-5px);
}

/* Sections */
section {
    padding: 80px 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 80px;
    height: 4px;
    background-color: var(--primary);
}

/* About Section */
.about {
    position: relative;
}

.about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at bottom left, rgba(56, 182, 255, 0.1), transparent 40%);
    z-index: -1;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.about-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.about-card {
    background-color: var(--dark-light);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    height: auto;
    border-top: 3px solid var(--primary);
    position: relative;
    overflow: hidden;
}

.about-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, transparent 0%, rgba(56, 182, 255, 0.05) 100%);
    pointer-events: none;
}

.about-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.about-header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    color: var(--primary);
}

.about-header i {
    font-size: 1.5rem;
    margin-right: 1rem;
    background: rgba(56, 182, 255, 0.1);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(56, 182, 255, 0.3);
}

.about-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
}

.about-card p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
    margin-bottom: 0;
}

/* Skills Section */
.skills-section {
    background-color: var(--dark-light);
    border-radius: var(--border-radius);
    padding: 1.5rem 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    width: 100%;
}

.skills-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(56, 182, 255, 0.1), transparent 70%);
    border-radius: 50%;
    z-index: 0;
}

.skills-title {
    text-align: center;
    width: 100%;
    margin-bottom: 1.5rem;
    font-size: 1.4rem;
    color: var(--primary);
    position: relative;
    display: block;
}

.skills-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background-color: var(--primary);
}

.skills-container {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 1.2rem;
    justify-content: center;
    width: 100%;
    position: relative;
    z-index: 1;
    margin-top: 1rem;
}

.skill-card {
    background-color: rgba(0, 0, 0, 0.2);
    padding: 1rem 0.6rem;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: auto;
}

.skill-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3), 0 0 15px rgba(56, 182, 255, 0.3);
}

.skill-icon {
    font-size: 2.2rem;
    margin-bottom: 0.7rem;
    text-shadow: 0 0 10px rgba(56, 182, 255, 0.5);
}

/* Skill Icon Colors */
.skill-icon-html { color: #E34F26; }
.skill-icon-css { color: #1572B6; }
.skill-icon-js { color: #F7DF1E; }
.skill-icon-node { color: #339933; }
.skill-icon-bootstrap { color: #7952B3; }
.skill-icon-mysql { color: #00758F; }
.skill-icon-git { color: #F05032; }
.skill-icon-angular { color: #DD0031; }
.skill-icon-react { color: #61DAFB; }
.skill-icon-java { color: #007396; }
.skill-icon-php { color: #777BB3; }
.skill-icon-python { color: #3776AB; }

.skill-name {
    font-size: 0.85rem;
}

/* Projects Section */
.projects {
    position: relative;
}

.projects::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(56, 182, 255, 0.1), transparent 40%);
    z-index: -1;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.project-card {
    background-color: var(--dark-light);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.project-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.project-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-title {
    font-size: 1.2rem;
    margin-bottom: 0.8rem;
    color: var(--text);
}

.project-description {
    color: var(--text-secondary);
    margin-bottom: 1.2rem;
    font-size: 0.9rem;
    line-height: 1.5;
    flex-grow: 1;
}

.project-tech {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
}

/* Contact Section */
.contact {
    position: relative;
}

.contact::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at bottom left, rgba(56, 182, 255, 0.1), transparent 40%);
    z-index: -1;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.contact-info {
    color: var(--text-secondary);
}

.contact-text {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.8;
}

.contact-form {
    background-color: var(--dark-light);
    padding: 2.5rem;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    transition: height 0.3s ease;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-input {
    width: 100%;
    padding: 1rem;
    background-color: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 5px;
    color: var(--text);
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    transition: var(--transition);
}

.form-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-input:focus {
    outline: none;
    background-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 2px var(--primary);
    border: 1px solid var(--primary);
    box-shadow: 0 0 15px rgba(56, 182, 255, 0.3);
}

textarea.form-input {
    min-height: 150px;
    resize: vertical;
}

.submit-btn {
    width: 100%;
    margin-top: 1rem;
}

.submit-btn.loading {
    background-color: var(--dark-light) !important;
    cursor: not-allowed;
}

.fa-spinner {
    margin-right: 8px;
}

.fa-spin {
    animation: spin 1s infinite linear;
}

.form-success-message {
    background-color: rgba(56, 182, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    margin-top: 2rem;
    border: 1px solid rgba(56, 182, 255, 0.3);
    animation: fadeInUp 0.5s ease;
}

.success-icon {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1rem;
    animation: pulse 2s infinite;
}

.success-icon i {
    animation: scale 0.5s ease;
}

/* Footer */
footer {
    background-color: var(--dark-light);
    padding: 3rem 0;
    margin-top: 3rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-social {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a::before {
    display: none;
}

.footer-links a:hover {
    color: var(--primary);
    text-shadow: 0 0 8px rgba(56, 182, 255, 0.5);
}

.copyright {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Animations */
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes scale {
    0% { transform: scale(0); }
    70% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

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

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */

@media (max-width: 1200px) {
    .hero-title {
        font-size: 3rem;
    }
    .profile-img {
        width: 300px;
        height: 300px;
    }
    .skills-container {
        grid-template-columns: repeat(5, 1fr);
    }
}

@media (max-width: 992px) {
    .container {
        padding: 0 1.5rem;
    }
    .hero-content, .about-content, .contact-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    .hero-image {
        order: -1;
        margin-top: 4rem;
        margin-bottom: 2rem;
    }
    .profile-img {
        width: 250px;
        height: 250px;
    }
    .about-info {
        grid-template-columns: repeat(3, 1fr);
    }
    .skills-container {
        grid-template-columns: repeat(4, 1fr);
    }
    header .social-links {
        display: none;
    }
}

@media (max-width: 850px) and (min-width: 768px) {
    .hero-content {
        gap: 2rem;
    }
    .profile-img {
        width: 260px;
        height: 260px;
    }
    .orbit-1 {
        width: 350px;
        height: 200px;
    }
    .orbit-2 {
        width: 450px;
        height: 260px;
    }
    .orbit-3 {
        display: none;
    }
}

@media (max-width: 768px) {
    html {
        scroll-padding-top: 80px; /* Ajuste para navegación fija */
    }
    section {
        min-height: auto;
        padding: 60px 0;
    }
    .nav-links, .header-right-controls {
        display: none;
    }
    .menu-btn {
        display: block;
        position: relative;
        width: 30px;
        height: 20px;
        cursor: pointer;
        z-index: 1001;
    }
    .menu-btn i {
        transition: all 0.3s ease;
    }
    .menu-open .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        padding: 2rem;
        z-index: 1000;
        animation: slideDown 0.3s ease;
        background: rgba(10, 15, 35, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 0 0 15px 15px;
        box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
        transition: all 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    }
    .nav-links a {
        font-size: 1.1rem;
        padding: 1rem 0;
        text-align: center;
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    .nav-links a:last-child {
        border-bottom: none;
    }
    .menu-open .menu-btn i.fa-bars {
        transform: rotate(90deg);
        opacity: 0;
    }
    .menu-open .menu-btn i.fa-times {
        transform: rotate(0deg);
        opacity: 1;
    }
    .hero {
        height: auto;
        min-height: 100vh;
        padding: 120px 0 60px;
    }
    .hero-title {
        font-size: 2.2rem;
    }
    .hero-description {
        font-size: 1rem;
    }
    .hero-buttons {
        display: grid;
        grid-template-columns: 1fr;
        gap: 1rem;
        width: 100%;
    }
    .btn {
        width: 100%;
        text-align: center;
        padding: 1rem;
    }
    .btn-outline {
        margin-left: 0;
    }
    .hero-social {
        justify-content: center;
    }
    .profile-img {
        width: 200px;
        height: 200px;
        margin: 0 auto 30px;
    }
    .section-title {
        text-align: center;
        margin-left: auto;
        margin-right: auto;
    }
    .section-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    .about, .projects, .contact {
        padding: 80px 0;
    }
    .about-info {
        grid-template-columns: 1fr;
    }
    .skills-container {
        grid-template-columns: repeat(3, 1fr);
    }
    .projects-grid {
        grid-template-columns: 1fr;
    }
    .project-card {
        height: auto;
        min-height: 400px;
    }
    .project-tech {
        position: relative;
        bottom: auto;
        left: auto;
        margin-top: 1rem;
    }
    .form-input {
        padding: 1.2rem;
        font-size: 16px; /* Evita el zoom en iOS */
    }
    textarea.form-input {
        min-height: 120px;
    }
    .submit-btn {
        padding: 1.2rem;
    }
    .footer-links {
        flex-wrap: wrap;
        gap: 1rem 2rem;
    }
    .particles {
        opacity: 0.5; /* Reducir opacidad para mejorar contraste */
    }
    @keyframes slideDown {
        from { opacity: 0; transform: translateY(-10px); }
        to { opacity: 1; transform: translateY(0); }
    }
}

@media (min-width: 769px) and (max-width: 991px) {
    .nav-links {
        gap: 1.5rem;
    }
    .container {
        padding: 0 1rem;
    }
    .about-content, .contact-content {
        gap: 2rem;
    }
    .skills-container {
        padding: 1.5rem;
    }
    .project-card {
        height: 420px;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }
    .section-title {
        font-size: 2rem;
    }
    .skills-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .form-input {
        font-size: 16px; /* Evita zoom automático en iOS */
    }
    textarea.form-input {
        min-height: 120px; /* Reduce altura para móviles */
    }
}

@media (max-width: 380px) {
    .hero-title {
        font-size: 1.8rem;
    }
    .profile-img {
        width: 180px;
        height: 180px;
    }
    .hero-social {
        flex-wrap: wrap;
        justify-content: center;
    }
    .section-title {
        font-size: 1.8rem;
    }
    .project-image {
        height: 160px;
    }
}

@media (max-width: 360px) {
    .container {
        padding: 0 0.8rem;
    }
    .hero-title {
        font-size: 1.6rem;
    }
    .hero-greeting {
        font-size: 1rem;
    }
    .project-title {
        font-size: 1.1rem;
    }
    .about-header h3 {
        font-size: 1.1rem;
    }
    .form-input {
        padding: 0.8rem;
    }
    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
    .btn {
        padding: 0.8rem 1.5rem;
    }
    .btn-outline {
        margin-left: 0;
    }
}

@media (max-height: 500px) and (min-width: 500px) {
    .hero {
        height: auto;
        padding: 120px 0 60px;
    }
    section {
        min-height: auto;
        padding: 50px 0;
    }
    .hero-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    .profile-img {
        width: 180px;
        height: 180px;
    }
    .about-info {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
    .about-card {
        padding: 1rem;
    }
    .skills-container {
        grid-template-columns: repeat(10, 1fr);
        gap: 0.8rem;
    }
    .skill-card {
        padding: 0.6rem;
    }
    .skill-icon {
        font-size: 1.8rem;
        margin-bottom: 0.4rem;
    }
    .skill-name {
        font-size: 0.7rem;
    }
}

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .profile-img {
        border-width: 3px;
    }
    .skill-icon {
        text-shadow: 0 0 8px rgba(56, 182, 255, 0.4);
    }
}

@supports (-webkit-touch-callout: none) {
    .btn {
        -webkit-appearance: none; /* Corrige apariencia de botones en iOS */
    }
}