:root {
    --bg: #05070a;
    --card-bg: #0C1322;
    --primary: #3b82f6;
}

body { 
    box-sizing: border-box;
    background: var(--bg); 
    color: white; 
    height: 100dvh;
    display: grid;
grid-template-rows: 1fr auto;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 5px;
    background-color: #070819;
    background-image: 
        radial-gradient(circle, transparent 40%, rgba(0, 0, 0, 0.03) 100%),
        linear-gradient(to bottom, rgba(0, 150, 255, 0.1) 1px, transparent 1px),
        linear-gradient(to right, rgba(0, 150, 255, 0.1) 1px, transparent 1px);
    background-size: 100% 100%, 1px 40px, 40px 30px;
    overflow: hidden;
}
h1{
    font-size: 28px;
    text-align: center;
    font-family: "inter" roboto;
    font-weight: 800;
    max-width: 73%; 
    margin: 0 auto;
    
}

h2 {
    text-align: center;
}
.screen {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}
.card {
    background: var(--card-bg);
    border-radius: 25px;
    width: 280px;
    padding: 0.2rem 1rem 2rem 1rem;
    position: relative;
    border: 1px solid #1e293b;
    margin: 15px auto;
}
.card::before, .card::after{
    content: "";
    position: absolute;
 left: 10%; right: 10%;
    height: 1.5px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    box-shadow: 0 0 15px var(--primary);
}
.card::before{
    top: 0;
}
.card::after{
    bottom: 0;
}
#word-input {
    padding: 16px;
    border: 1px solid #1e293b;
    background: transparent;
    border-radius: 15px;
    color: #F1F1F1;
    font-weight: 300;
    flex: 0.5;
}

#word-input:hover {
    outline: none;
    box-shadow: 0 0 3px 2px var(--primary);
}

.search-ctn {
    display: flex;
    gap: 5px;
    align-items: center;
}

#search-btn {
    padding: 10px;
    border: 1px solid #1e293b;   
    border-radius: 100%;
    background: none;
    color: #F1F1F1;
    cursor: pointer;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#search-btn:hover {
    box-shadow: 0 0 3px 2px var(--primary);
}

.error-text {
    color: #FB1B1BD4;
    transform: translateY(-63px);
    font-size: 9pt;
    font-weight: bold;
    
}
.network-err {
    padding: 5px; 
    width: 260px;
    border-radius: 8px;
    background-color: #F8F7FF;
    color: #0F0F0F;
    font-weight: 400;
    font-size: 15px;
    position: absolute;
    top: 180px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    opacity: 90%;
    transition: opacity 0.9s ease;
}


#result-screen{
    display: none;
    text-align: center;
}
.icon-btn {
    border: none;
    border-radius: 100px;
    padding: 0;
    width: 40px;
    height: 40px;
    background: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
a[href^="https://en.wikipedia.org"]::after {
        content: "↗";
        font-size: 0.8em;
        vertical-align: super;
        color: var(--primary);
        margin-left: 4px;
        font-weight: bold;
    }


#back-btn {
    border: 0.9px solid #4E4EFF;
    padding: 8px 22px;
    border-radius: 10px;
    background-color: hsla(235, 83%, 31%, 0.94);
    color: #4E4EFF;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 20px;
}

#back-btn:hover {
    opacity: 0.9;
}

.screen {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}
#word-display {
    margin: 20px 0;
    line-height: 1.6;
}
#footer-section{
    margin: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    text-align: center;
    filter: invert(0.5);
}
.footer-icon{
   width: 15px;
  height: 15px;
  display: block;
  transition: 0.3s;
}
