/* ===============================
AVF GLOBAL GRID
=============================== */
.avf-directory {display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));gap: 15px;}

/* ===============================
MEMBER CARD
=============================== */
.avf-member-card {position: relative; background: #fff; box-shadow:0 10px 25px rgba(0,0,0,0.06), inset 0 0 0 1px rgba(255,255,255,0.4); text-align:center; transition:all .35s ease; overflow:hidden; padding:15px 10px;}
.avf-member-card:hover {transform: translateY(-8px) scale(1.02);box-shadow: 0 20px 40px rgba(0,0,0,0.12);}

/* ===============================
HEADER IMAGE (FULL WIDTH OPTION)
=============================== */
.avf-member-card .avf-cover {width: 100%; height: 110px;object-fit: cover; border-radius: 14px 14px 0 0;margin-bottom: -55px; border:1px solid #ccc;}

/* ===============================
AVATAR
=============================== */
.avf-directory .avf-card-header {display:block; margin-bottom:0px;}
.avf-member-card img, .elementor .avf-member-card img {border-radius: 50%;  object-fit: cover;  margin-bottom: 10px; border: 0px solid rgba(255,255,255,0);  box-shadow: 0 4px 12px rgba(0,0,0,0.1);width: 90px;
height: 90px;background: #f5f5f5;}
.avf-member-card:hover img, .avf-dir-card:hover img {transform: scale(1.05);border-color:#2c7be5;  box-shadow:0 0 18px rgba(44,123,229,0.8);}

/* ===============================
NAME & ID
=============================== */
.avf-member-name {font-weight: 600; font-size: 14px;margin-top: 6px; margin-bottom: 0px;color: #222;}
.avf-member-id, .avf-user-type, .avf-location {font-size: 12px; color: #2b6cff;font-weight: 500;  margin-top: 3px;  }
.avf-user-type {color: #444; margin-bottom: 10px;}
.avf-location {color: #666; margin-bottom: 10px; }

/* ===============================
❤️ FAVORITE BUTTON (PREMIUM)
=============================== */
.fav-btn, .avf-favorites-page .fav-btn {
position: absolute;
top: 6px;
right: 6px;
width: 32px;
height: 32px;
border-radius: 50%;
border: none;
cursor: pointer;
background: rgba(255,255,255,0.9);
box-shadow: 0 5px 15px rgba(0,0,0,0.08);
display: flex;
align-items: center;
justify-content: center;
transition: all 0.25s ease;
}

/* Heart icon */
.fav-btn .heart::before {
content: "❤";
font-size: 16px;
color: #bbb;
transition: all 0.25s ease;
}

/* Active state */
.fav-btn.active .heart::before {
color: #ff3b5c;
}

/* Hover effect */
.fav-btn:hover {
transform: scale(1.1);
}

/* Click animation */
.fav-btn.animate {
transform: scale(1.25);
}

/* ===============================
REMOVE BUTTON (HIDDEN BY DEFAULT)
=============================== */
.remove-fav-btn {
display: none !important;
}

/* ===============================
FAVORITES PAGE CLEAN
=============================== */
.avf-favorites-page .fav-btn {
background: #fff;
}

/* ===============================
EMPTY STATE
=============================== */
.avf-favorites-page p {
text-align: center;
width: 100%;
font-size: 16px;
color: #777;
padding: 40px 0;
}

/* ===============================
TOAST
=============================== */
.avf-toast {
position: fixed;
bottom: 20px;
right: 20px;
background: #222;
color: #fff;
padding: 10px 16px;
border-radius: 8px;
opacity: 0;
transform: translateY(20px);
transition: 0.3s ease;
z-index: 9999;
}

.avf-toast.show {
opacity: 1;
transform: translateY(0);
}

/* SEARCH INPUT */
input[type="text"].search { width: 100%; max-width: 100%;  padding: 15px 15px; border-radius: 10px; border: 1px solid #ddd; margin-bottom: 20px;outline: none; height:auto; line-height:normal;}
input[type="text"].search:focus { border-color: #111;}
/* =====================================================
VERTICAL PROFESSIONAL AVF ID CARD
Full width logo, bigger watermark and photo
===================================================== */

.avf-id-card-container{
display:flex;
flex-wrap:wrap;
gap:30px;
justify-content:center;
font-family:'Segoe UI', sans-serif;
margin:20px 0;
}

/* Card base */
.avf-id-card{
width:280px;
height:480px!important;
border-radius:12px;
box-shadow:0 4px 15px rgba(0,0,0,0.1);
border:1px solid #ddd;
background:#fff;
overflow:hidden;
display:flex;
flex-direction:column;
position:relative;
}

/* Top & Bottom gradient borders */
.avf-id-card .top-border,
.avf-id-card .bottom-border{
height:8px;
background: linear-gradient(90deg,#4a90e2,#9013fe);
}
/* FRONT CARD */
.front-card {
display: flex;
flex-direction: column;
justify-content: flex-start; /* Pushes bottom border to bottom */
height: 100%;
position: relative;
}

.front-card .front-body{
padding: 10px 20px;
position: relative;
z-index: 1;
}

.front-card .bottom-border{
position: absolute;
bottom: 0;
left: 0;
width: 100%;
height: 8px;
background: linear-gradient(90deg,#4a90e2,#9013fe);
}
/* Signature Label */
.front-card .signature-label{
font-size:0.85em;
font-weight:600;
text-align:center;
margin-top:15px;
margin-bottom:5px;
color:#333;
}
/* Watermark */
.front-card .watermark{
position:absolute;
top:50%;
left:50%;
width:250px;
height:250px;
opacity:0.08;
transform:translate(-50%,-50%);
background-repeat:no-repeat;
background-size:contain;
pointer-events:none;
z-index:0;
}

/* Logo Full Width */
.front-card .logo{
width:100%;
display:block;
margin:20px auto 30px auto;
z-index:1;
position:relative;
}
 auto
.front-card .logo-border{
height:1px;
background:#ccc;
margin:5px 0 10px 0;
}

/* Photo Bigger */
.front-card .photo{
width:120px;
height:120px;
border-radius:50%;
object-fit:cover;
border:2px solid #ddd;
display:block;
margin:10px auto;
z-index:1;
position:relative;
}

/* Name and Role */
.front-card .sub-title{
font-size:1.4em;
font-weight:700;
text-align:center;
margin:5px 0;
z-index:1;
position:relative;
}

.front-card .role{
font-size:1em;
font-weight:600;
text-align:center;
margin-bottom:5px;
}

/* Info */
.front-card p{
font-size:0.95em;
text-align:center;
margin:2px 0;
}

/* Signature */
.front-card .signature{
width:130px;
display:block;
margin:0px auto 0 auto;
}

/* BACK CARD */
.back-card .back-body{
padding:20px;
display:flex;
flex-direction:column;
align-items:center;
justify-content:center; /* Contact info at bottom */
height:100%;
}

.back-card .qr{
width:120px;
height:120px;
margin-bottom:10px;
border:2px solid #ddd;
border-radius:10px;
}

.back-card .back-info{
text-align:center;
}

.back-card .back-info p{
margin:3px 0;
font-size:0.95em;
}

/* TABS */
.avf-tabs{display:flex; flex-wrap:wrap; gap:6px; margin-bottom:10px;}
.avf-tab{ padding:6px 8px; border-radius:4px; background:#f1f1f1; cursor:pointer; font-weight:700;  transition:0.3s; font-size:12px;}
.avf-tab.active{background:#111;color:#fff;}


/* OVERLAY */
.avf-login-overlay{
position:fixed;
top:0;
left:0;
width:100%;
height:100%;
background:rgba(0,0,0,0.65);
display:flex;
align-items:center;
justify-content:center;
z-index:99999;
}

/* BOX */
.avf-login-box{
background:#fff;
padding:30px;
width:100%;
max-width:380px;
border-radius:12px;
text-align:center;
position:relative;
animation:avfFadeIn 0.3s ease;
}

/* ANIMATION */
@keyframes avfFadeIn{
from{transform:translateY(20px);opacity:0;}
to{transform:translateY(0);opacity:1;}
}

/* CLOSE BUTTON */
.avf-close{
position:absolute;
top:12px;
right:15px;
font-size:30px;
cursor:pointer;
}

/* HEADINGS */
.avf-login-box h3{
margin-bottom:5px;
}

.subtitle{
font-size:14px;
color:#777;
margin-bottom:20px;
}

/* INPUT */
.input-group{
margin-bottom:15px;
}

.input-group input{
width:100%;
padding:12px;
border:1px solid #ddd;
border-radius:6px;
font-size:14px;
}


.primary-btn{
background:#0073aa;
color:#fff;
font-weight:600;
}

.primary-btn:hover{
background:#005f8d;
}

/* ERROR */
.avf-login-error{
color:red;
font-size:13px;
margin-top:10px;
}

/* LINKS */
.avf-extra-links{
margin-top:15px;
font-size:13px;
}

.avf-extra-links a{
color:#0073aa;
text-decoration:none;
}



.avf-actions{
    display:grid;
    grid-template-columns: repeat(3, 1fr);
    gap:12px;
    margin-top:20px;
}

.avf-btn{display:flex; align-items:center; gap:10px;padding:12px;  border-radius:16px;  text-decoration:none; box-shadow:0 6px 18px rgba(0,0,0,0.08); transition:all 0.25s ease;position:relative; overflow:hidden;background:#fff!important;
}

/* ICON */
.avf-btn .icon{
    font-size:20px;
    background:#f5f5f5;
    padding:10px;
    border-radius:10px;
}

/* TEXT */
.avf-btn small{
    display:block;
    font-size:11px;
    color:#777;
}

.avf-btn b{
    font-size:14px;
    color:#111;
}

/* HOVER EFFECT */
.avf-btn:hover{
    transform:translateY(-4px);
    box-shadow:0 12px 30px rgba(0,0,0,0.15);
}

/* COLOR ACCENTS */
.avf-btn.call{border-left:4px solid #28a745;}
.avf-btn.whatsapp{border-left:4px solid #25D366;}
.avf-btn.map{border-left:4px solid #007bff;}


.avf-download-btn{
    background: linear-gradient(135deg,#6a11cb,#2575fc);
    color:#fff;
    border:none;
    padding:10px 18px;
    border-radius:8px;
    cursor:pointer;
    margin-bottom:15px;
    font-weight:600;
}
.avf-download-btn:hover{
    opacity:0.9;
}

.avf-download-btn:disabled{
    opacity:0.6;
    cursor:not-allowed;
}

/* CARD */
.avf-membership-card {
    background: #fff;
    border-radius: 16px;
    border: 1px solid #eaeaea;
    padding: 20px 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.04);
    transition: 0.3s;
}

.avf-membership-card:hover {
    box-shadow: 0 8px 22px rgba(0,0,0,0.06);
}

/* HEADER */
.avf-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.avf-card-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #222;
}

/* BADGE */
.avf-badge {
    padding: 8px 14px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase; letter-spacing: 1px;
}

/* Plan Colors */
.avf-badge.free { background:#e5e7eb; color:#333; }
.avf-badge.gold { background:linear-gradient(45deg,#f59e0b,#f97316); color:#fff; }
.avf-badge.leader { background:linear-gradient(45deg,#4f46e5,#7c3aed); color:#fff; }
.avf-badge.silverplan{background:linear-gradient(135deg,#f6c343,#ffb100); color:#fff;}

/* BODY */
.avf-card-body {display: flex; flex-direction: column; gap: 10px;}

/* INFO ROW */
.avf-info-row { display: flex; justify-content: space-between; align-items: center; font-size: 14px;}

.avf-info-row span {color: #777;}
.avf-info-row strong {color: #222;font-weight: 600;}

/* DAYS COLORS */
.avf-days {font-weight: 600;}
.avf-days.danger {color: #dc2626;}
.avf-days:not(.danger) {color: #16a34a;}

/* PROGRESS BAR */
.avf-progress {
    height: 6px;
    background: #ccc;
    border-radius: 20px;
    overflow: hidden;
    margin-top: 10px;
}

.avf-progress-bar {
    height: 100%;
    background: linear-gradient(90deg,#4f46e5,#7c3aed);
    transition: width 0.4s ease;
}

/* FOOTER */
.avf-card-footer {
    margin-top: 0px;
    text-align: right;
}

/* BUTTON */
.avf-upgrade-btn {
    display: inline-block;
    background: linear-gradient(45deg,#f59e0b,#f97316);
    color: #fff!important;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 14px;
    text-decoration: none;
    font-weight: 500;
    transition: 0.3s;
}

.avf-upgrade-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

#avf-district{
    display:block !important;
    width:100%;
    margin-top:10px;
}


/* Responsive */
@media(max-width:768px){
.avf-member-card {padding: 15px 10px;}
.avf-member-card img {width: 70px;height: 70px;}
.avf-directory{ grid-template-columns:repeat(auto-fit,minmax(120px,1fr)); }
.avf-member-card{ padding:12px 10px 8px 10px;}
.avf-member-name{ font-size:16px; }
.avf-member-role{ font-size:13px; }
.avf-member-id{ font-size:14px; }
.avf-actions{grid-template-columns:1fr;}
}

@media (max-width:600px){
.avf-id-card-container{
flex-direction:column;
align-items:center;
}
}
@media(max-width:480px){
.avf-directory{grid-template-columns: repeat(2, 1fr); /* 🔥 8 per row */}
.avf-member-name{ font-size:15px; }
.avf-member-role{ font-size:12px; }
.avf-member-id{ font-size:13px; }
}
